Fix problem with ReferenceProperty assigning when type definition has been changed