Skip to content

Commit 590fc48

Browse files
committed
[BUGFIX beta] Normalize attrs inside the links object when using the JSONSerializer and RestSerializer.
(cherry picked from commit fd0e320)
1 parent 21bae25 commit 590fc48

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

addon/serializers/json.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -524,6 +524,9 @@ export default Serializer.extend({
524524

525525
if (resourceHash) {
526526
this.normalizeUsingDeclaredMapping(modelClass, resourceHash);
527+
if (Ember.typeOf(resourceHash.links) === 'object') {
528+
this.normalizeUsingDeclaredMapping(modelClass, resourceHash.links);
529+
}
527530

528531
data = {
529532
id: this.extractId(modelClass, resourceHash),

0 commit comments

Comments
 (0)