Merge "Fix NPE for MATCH_FACTORY_ONLY" into nyc-dev