mirror of
https://github.com/zhigang1992/RestKit.git
synced 2026-04-24 04:46:01 +08:00
Fix horrible bugs in previous commit
This commit is contained in:
@@ -151,7 +151,7 @@ extern NSString * const RKObjectMappingNestingAttributeKeyName;
|
||||
[self emitDeadlockWarningIfNecessary];
|
||||
|
||||
NSArray *connectionMappings = [(RKEntityMapping *)mappingOperation.objectMapping connectionMappings];
|
||||
if ([connectionMappings count] > 0) {
|
||||
if ([connectionMappings count] > 0 && self.managedObjectCache == nil) {
|
||||
NSDictionary *userInfo = @{ NSLocalizedDescriptionKey: @"Cannot map an entity mapping that contains connection mappings with a data source whose managed object cache is nil." };
|
||||
NSError *localError = [NSError errorWithDomain:RKErrorDomain code:RKMappingErrorNilManagedObjectCache userInfo:userInfo];
|
||||
if (error) *error = localError;
|
||||
|
||||
Reference in New Issue
Block a user