Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Fix ordered relationships #66

Merged
merged 1 commit into from

2 participants

@MSch

Set accessor generates wrong mutableSet method

@rentzsch rentzsch merged commit 4cab306 into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jul 12, 2011
  1. @MSch
This page is out of date. Refresh to see the latest.
Showing with 4 additions and 0 deletions.
  1. +4 −0 templates/machine.m.motemplate
View
4 templates/machine.m.motemplate
@@ -71,7 +71,11 @@
<$if Relationship.isToMany$>
- (<$Relationship.mutableCollectionClassName$>*)<$Relationship.name$>Set {
[self willAccessValueForKey:@"<$Relationship.name$>"];
+ <$if Relationship.isOrdered$>
+ <$Relationship.mutableCollectionClassName$> *result = (<$Relationship.mutableCollectionClassName$>*)[self mutableOrderedSetValueForKey:@"<$Relationship.name$>"];
+ <$else$>
<$Relationship.mutableCollectionClassName$> *result = (<$Relationship.mutableCollectionClassName$>*)[self mutableSetValueForKey:@"<$Relationship.name$>"];
+ <$endif$>
[self didAccessValueForKey:@"<$Relationship.name$>"];
return result;
}
Something went wrong with that request. Please try again.