emberjs/data — pull request #1972 by pixelhandler (2014-05-23 22:38:09+00:00)
Title: DS.EmbeddedRecordsMixin methods for serializing relationships call super

[Fixes #1971]

The `serializeBelongsTo` and `serializeHasMany` may need to call super.

In the case of using the mixin with `DS.ActiveModelSerializer` the `serializeHasMany` method is a no-op `Em.K` but if the mixin is used with another serializer (e.g. extending `DS.RESTSerializer`) that does use `serializeBelongsTo` and `serializeHasMany` hooks, then the DS.EmbeddedRecordsMixin should call super when the `attrs` setting is not set for a relationship (the default behavior would be used for not embedding).

*Use case:( A serializer is setup with multiple hasMany/belongsTo relationships where some are embedded and some are not. Those methods for `serializeBelongsTo` and `serializeHasMany` call `_super` if the `attrs` property (config) doesn't have the relationship being serialized as setup for embedding.