public function getPlaylistById($id) { $controller = $this->getController(); if ($controller === null) { throw new \RuntimeException("No controller found on the current network"); } return new Playlist($id, $controller); }