Merge pull request #734 from mikeopensauce/726apionairfix
Bugfix for #726. Fixes onAirLightAction returning 500 error
This commit is contained in:
commit
e13fc6b3d9
|
@ -178,6 +178,7 @@ class ApiController extends Zend_Controller_Action
|
|||
//Used by the SaaS monitoring
|
||||
public function onAirLightAction()
|
||||
{
|
||||
$request = $this->getRequest();
|
||||
$this->view->layout()->disableLayout();
|
||||
$this->_helper->viewRenderer->setNoRender(true);
|
||||
|
||||
|
@ -188,9 +189,9 @@ class ApiController extends Zend_Controller_Action
|
|||
|
||||
$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 ||
|
||||
Application_Model_Preference::GetSourceSwitchStatus("live_dj") == "on" ||
|
||||
|
|
Loading…
Reference in New Issue