I have changed my apps model a bit compared to the last release. I am going to use lightweight migration. I added a new model version and selected it as the model to be used in 'Model Version' in File inspector of the model.
I want to know if I should also change the name of the model from OldModelName to NewModelName in line 6 (below) where I generate the URL for the model, when initializing the stack for the first time...
- (NSManagedObjectModel *)managedObjectModel
{
if (_managedObjectModel != nil) {
return _managedObjectModel;
}
NSURL *modelURL = [[NSBundle mainBundle] URLForResource:@"OldModelName" withExtension:@"momd"];
_managedObjectModel = [[NSManagedObjectModel alloc] initWithContentsOfURL:modelURL];
return _managedObjectModel;
}
Neerav