When converting plain-data object values into model instances, correctly handle the case where the constructor functions is a class constructor and must be invoked via `new`.