Make sure NSManagedObjectModel objects aren't nil before attempting a migration.

Otherwise it will throw an exception.