provide fallback podcast name for smartblock creation from popup

This commit is contained in:
ryan 2018-12-15 06:54:03 -06:00
parent 91e3bdfd2f
commit 29501528a9

View file

@ -166,12 +166,15 @@ class Application_Service_PodcastService
* This will automatically create a smartblock and playlist for this podcast.
*/
public static function createPodcastSmartblockAndPlaylist($podcast, $title)
public static function createPodcastSmartblockAndPlaylist($podcast, $title = "Podcast")
{
if (is_array($podcast)) {
$newpodcast = new Podcast();
$newpodcast->fromArray($podcast, BasePeer::TYPE_FIELDNAME);
$podcast = $newpodcast;
if ($title == "Podcast") {
$title = $podcast->getDbTitle();
}
}
// Base class
$newBl = new Application_Model_Block();