diff --git a/ChangeLog b/ChangeLog index b3ce58a..6857c31 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,9 +1,15 @@ +2008-05-03 Matt Rice + + * EOAccess/EOEntity.m (-[isValidPrimaryKeyAttribute:], + -[isValidAttributeUsedForLocking:], + -[isValidClassProperty:]): Test object equality as well as name. + 2008-05-01 David Ayers * EOAccess/EODatabaseContext.m ([-initializeObject:row:entity:editingContext:]): Remove debug logs. * EOAccess/EOEntity.m ([-_dictionaryForInstanceProperties], - [-primaryKeyForGlobalID:]) Remove debug logs. + [-primaryKeyForGlobalID:]): Remove debug logs. 2008-05-01 Matt Rice diff --git a/EOAccess/EOEntity.m b/EOAccess/EOEntity.m index 16af828..927ff90 100644 --- a/EOAccess/EOEntity.m +++ b/EOAccess/EOEntity.m @@ -1432,7 +1432,7 @@ static void performSelectorOnArrayWithEachObjectOfClass(NSArray *arr, SEL select - (BOOL)isValidAttributeUsedForLocking: (EOAttribute *)attribute { if (!([attribute isKindOfClass: GDL2_EOAttributeClass] - && [[self attributesByName] objectForKey: [attribute name]])) + && ([self attributeNamed: [attribute name]] == attribute))) return NO; if ([attribute isDerived]) @@ -1444,7 +1444,7 @@ static void performSelectorOnArrayWithEachObjectOfClass(NSArray *arr, SEL select - (BOOL)isValidPrimaryKeyAttribute: (EOAttribute *)attribute { if (!([attribute isKindOfClass: GDL2_EOAttributeClass] - && [[self attributesByName] objectForKey: [attribute name]])) + && ([self attributeNamed: [attribute name]] == attribute))) return NO; if ([attribute isDerived]) @@ -1496,8 +1496,8 @@ static void performSelectorOnArrayWithEachObjectOfClass(NSArray *arr, SEL select thePropertyName = [(EOAttribute *)property name]; - if ([[self attributesByName] objectForKey: thePropertyName] - || [[self relationshipsByName] objectForKey: thePropertyName]) + if ([[self attributesByName] objectForKey: thePropertyName] == property + || [[self relationshipsByName] objectForKey: thePropertyName] == property) return YES; return NO;