diff --git a/src/json_api_serializer.js b/src/json_api_serializer.js index 7dadd54..f1fa4c7 100644 --- a/src/json_api_serializer.js +++ b/src/json_api_serializer.js @@ -85,7 +85,12 @@ DS.JsonApiSerializer = DS.RESTSerializer.extend({ } } - payload[link] = linked[link]; + if (payload[link]){ + payload[link].pushObjects(linked[link]); + }else{ + payload[link] = linked[link]; + } + delete linked[link]; } delete payload.linked;