Merge "Fix NPE introduced by ag/16740473." into tm-dev