import { ActiveModelSerializer } from 'ember-cli-mirage';

export default ActiveModelSerializer.extend({
  serialize(model, request) {
    let videoSerializer = this.serializerFor('video');
    return {
      game: model.game,
      releases: model.videos.models.map(v => videoSerializer.serialize(v, request))
    };
  }
});
