Add MOC reset to the beginning of resetPersistentStores:. closes #1018

This commit is contained in:
Blake Watters
2012-12-07 15:06:13 -05:00
parent 7eef2f2174
commit f4457f2948
2 changed files with 23 additions and 0 deletions

View File

@@ -212,6 +212,9 @@ static RKManagedObjectStore *defaultStore = nil;
- (BOOL)resetPersistentStores:(NSError **)error
{
[self.mainQueueManagedObjectContext reset];
[self.persistentStoreManagedObjectContext reset];
NSError *localError;
for (NSPersistentStore *persistentStore in self.persistentStoreCoordinator.persistentStores) {
NSURL *URL = [self.persistentStoreCoordinator URLForPersistentStore:persistentStore];