Ejemplo n.º 1
0
 public function getUnPublishedTracks()
 {
     $tracks = $this->tracks->toArray();
     return array_filter($tracks, function ($track) {
         return $track->getEvent() ? 0 : 1;
     });
 }
Ejemplo n.º 2
0
 /**
  * Removes a track from the playlist.
  *
  * @param  Track $track The track to remove from the playlist.
  * @return void
  */
 public function removeTrack(Track $track)
 {
     $this->tracks->remove($track->getId());
 }