mirror of
https://github.com/zhigang1992/RestKit.git
synced 2026-04-23 20:31:13 +08:00
Bug fix for potential invocation of setObject:forKey: with a nil key value
This commit is contained in:
@@ -335,7 +335,7 @@ static NSString* const RKManagedObjectStoreThreadDictionaryEntityCacheKey = @"RK
|
||||
id attributeValue = [theObject valueForKey:primaryKeyAttribute];
|
||||
// Coerce to a string if possible
|
||||
attributeValue = coerceToString ? [attributeValue stringValue] : attributeValue;
|
||||
if (primaryKeyValue) {
|
||||
if (attributeValue) {
|
||||
[dictionary setObject:theObject forKey:attributeValue];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user