import serialize from 'web-client/mirage/utils/serialize';
import { assign } from 'ember-platform';

export default function(server, vodId) {
  let vodAppeals = {
    vod_appeals: [
      server.create('vod-appeal', {
        title: 'Some track'
      })
    ]
  };

  server.get(`http://api.twitch.tv/api/vods/${vodId}/vod_appeals`, function() {
    return assign(serialize(this, vodAppeals));
  });

  let mutedTracks = {
    muted_tracks: [
      server.create('muted-track', {
        is_muted: true
    })
    ]
  };

  server.get(`http://api.twitch.tv/api/vods/${vodId}/muted_tracks`, function() {
    return assign(serialize(this, mutedTracks));
  });
}
