jeudi 23 juillet 2015

I didn't migrate NSPersistentStore in new version, can I recover with an app update?

long story short, my Core Data schema was changed, and my app was submitted to the app store, which caused everybody who updated their app to crash. The crash is caused by a missing NSPersistentStore due to not migrating the data model properly.

I still see the .sqlite and associated database files in the documents directory, and if I downgrade to the older version everything works fine with all data. My question is, can I recover from this with an app update by somehow migrating the existing NSPersistentStore and adding it to the NSPersistentStoreCoordinator?

Aucun commentaire:

Enregistrer un commentaire