Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- NSDictionary *options = @{
- NSMigratePersistentStoresAutomaticallyOption : @(YES),
- NSInferMappingModelAutomaticallyOption : @(YES)
- };
- sqlStore = [_persistentStoreCoordinator addPersistentStoreWithType:NSSQLiteStoreType
- configuration:nil
- URL:storeURL
- options:options
- error:&error];
- [[NSFileManager defaultManager] setAttributes:[NSDictionary dictionaryWithObject:NSFileProtectionNone forKey:NSFileProtectionKey] ofItemAtPath:storePath error:nil];
- while(![[UIApplication sharedApplication] isProtectedDataAvailable]) {
- [[NSRunLoop currentRunLoop] runUntilDate:[NSDate dateWithTimeIntervalSinceNow:0.5f]];
- }
- applicationProtectedDataDidBecomeAvailable:
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement