Bugfix for #726. Fixes onAirLightAction returning 500 error
This commit is contained in:
parent
17e12f023d
commit
7f69b1adf1
|
@ -178,6 +178,7 @@ class ApiController extends Zend_Controller_Action
|
||||||
//Used by the SaaS monitoring
|
//Used by the SaaS monitoring
|
||||||
public function onAirLightAction()
|
public function onAirLightAction()
|
||||||
{
|
{
|
||||||
|
$request = $this->getRequest();
|
||||||
$this->view->layout()->disableLayout();
|
$this->view->layout()->disableLayout();
|
||||||
$this->_helper->viewRenderer->setNoRender(true);
|
$this->_helper->viewRenderer->setNoRender(true);
|
||||||
|
|
||||||
|
@ -188,9 +189,9 @@ class ApiController extends Zend_Controller_Action
|
||||||
|
|
||||||
$range = Application_Model_Schedule::GetPlayOrderRange();
|
$range = Application_Model_Schedule::GetPlayOrderRange();
|
||||||
|
|
||||||
$isItemCurrentlyScheduled = !is_null($range["current"]) && count($range["currentShow"]) > 0 ? true : false;
|
$isItemCurrentlyScheduled = !is_null($range["tracks"]["current"]) && count($range["tracks"]["current"]) > 0 ? true : false;
|
||||||
|
|
||||||
$isCurrentItemPlaying = $range["current"]["media_item_played"] ? true : false;
|
$isCurrentItemPlaying = $range["tracks"]["current"]["media_item_played"] ? true : false;
|
||||||
|
|
||||||
if ($isItemCurrentlyScheduled ||
|
if ($isItemCurrentlyScheduled ||
|
||||||
Application_Model_Preference::GetSourceSwitchStatus("live_dj") == "on" ||
|
Application_Model_Preference::GetSourceSwitchStatus("live_dj") == "on" ||
|
||||||
|
|
Loading…
Reference in New Issue