Merge "Fix potential NPE in internal isValidTarget method." into mnc-dev