2
0

Fix usage of dubious objectID in global context.

This commit is contained in:
Maarten Billemont
2017-04-29 23:52:57 -04:00
parent 6d9be3fdfe
commit 834e94ebd5
10 changed files with 58 additions and 58 deletions

View File

@@ -74,11 +74,7 @@
- (void)setActiveUser:(MPUserEntity *)activeUser {
NSError *error;
if (activeUser.objectID.isTemporaryID && ![activeUser.managedObjectContext obtainPermanentIDsForObjects:@[ activeUser ] error:&error])
MPError( error, @"Failed to obtain a permanent object ID after setting active user." );
self.activeUserOID = activeUser.objectID;
self.activeUserOID = activeUser.permanentObjectID;
}
- (void)handleCoordinatorError:(NSError *)error {