diff --git a/api/app/Http/Controllers/NewsController.php b/api/app/Http/Controllers/NewsController.php index 2c83d33..947d12b 100644 --- a/api/app/Http/Controllers/NewsController.php +++ b/api/app/Http/Controllers/NewsController.php @@ -168,6 +168,10 @@ QUERY; $podcast = app('db')->select(PodcastController::$BASE_SQL . ' AND `podcast`.`id` = :podcastId', ['podcastId' => $blogItem->podcast_id]); $podcast = count($podcast) ? $podcast[0] : null; } + else + { + $podcast = null; + } $result[] = new \Model\NewsItem($blogItem, $pictures, $podcast); }