Skip to content

Commit

Permalink
Merge pull request #122 from monishsyed/ms-resetting-set-using-return…
Browse files Browse the repository at this point in the history
…ed-proxy

Reason: mutableOrderedSetValueForKey and mutableSetValueForKey now re…
  • Loading branch information
cnstoll committed Jan 10, 2017
2 parents 513dd84 + 6841e78 commit b305eb3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Source/MMRecord/MMRecordMarshaler.m
Original file line number Diff line number Diff line change
Expand Up @@ -198,9 +198,9 @@ + (void)establishToManyRelationship:(NSRelationshipDescription *)relationship
useOrderedSet = relationship.isOrdered ? YES : NO;
}
if (useOrderedSet) {
relationshipSet = [fromRecord mutableOrderedSetValueForKey:[relationship name]];
relationshipSet = [NSMutableOrderedSet orderedSetWithOrderedSet:[fromRecord mutableOrderedSetValueForKey:[relationship name]]];
} else {
relationshipSet = [fromRecord mutableSetValueForKey:[relationship name]];
relationshipSet = [NSMutableSet setWithSet:[fromRecord mutableSetValueForKey:[relationship name]]];
}

[relationshipSet addObject:toRecord];
Expand Down

0 comments on commit b305eb3

Please sign in to comment.