-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -120,7 +120,16 @@ DS.JSONSerializer = Ember.Object.extend({ | |
} | ||
}, | ||
|
||
serializeHasMany: Ember.K, | ||
serializeHasMany: function(record, json, relationship) { | ||
var key = relationship.key; | ||
|
||
var relationshipType = DS.RelationshipChange.determineRelationshipType(record.constructor, relationship); | ||
|
||
if (relationshipType === 'manyToNone' || relationshipType === 'manyToMany') { | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
ssured
Contributor
|
||
json[key] = get(record, key).mapProperty('id'); | ||
// TODO support for polymorphic manyToNone and manyToMany relationships | ||
} | ||
}, | ||
|
||
// EXTRACT | ||
|
||
|
What was the reasoning behind excluding manyToOne? was it to stop recursion in an embedded save?