diff --git a/airtime_mvc/application/models/Schedule.php b/airtime_mvc/application/models/Schedule.php index 6e6598a86..2cd573ef6 100644 --- a/airtime_mvc/application/models/Schedule.php +++ b/airtime_mvc/application/models/Schedule.php @@ -516,6 +516,9 @@ class Application_Model_Schedule { $showEndDateTime = new DateTime($item["show_end"], $utcTimeZone); $trackEndDateTime = new DateTime($item["ends"], $utcTimeZone); + /* Note: cue_out and end are always the same. */ + /* TODO: Not all tracks will have "show_end" */ + if ($trackEndDateTime->getTimestamp() > $showEndDateTime->getTimestamp()){ $diff = $trackEndDateTime->getTimestamp() - $showEndDateTime->getTimestamp(); //assuming ends takes cue_out into assumption