Attempt to fix playlist adding bug

This commit is contained in:
Josef Citrine 2016-11-21 01:08:45 +00:00
parent 926e410721
commit f85b1ecdeb
2 changed files with 2 additions and 2 deletions

View file

@ -179,7 +179,7 @@ class EditTrackCommand extends CommandBase
}
if (isset($this->_input['hwc_submit']) && new \DateTime() < new \DateTime("2016-12-18 00:00:00")) {
$playlist = Playlist::where('user_id', 22549)->first();
$playlist = Playlist::where('id', 658)->first();
if ($this->_input['hwc_submit'] === true) {
if (!$playlist->tracks()->get()->contains($track)) {

View file

@ -534,7 +534,7 @@ class Track extends Model implements Searchable, Commentable, Favouritable
$returnValue['username'] = User::whereId($track->user_id)->first()->username;
// Seasonal
$returnValue['hwc_submit'] = Playlist::where('user_id', 22549)->first()->tracks()->get()->contains($track);
$returnValue['hwc_submit'] = Playlist::where('id', 658)->first()->tracks()->get()->contains($track);
return $returnValue;
}