From eee885f7463f689d05c4fe5ba879fedf9b6e63cc Mon Sep 17 00:00:00 2001 From: martin Date: Fri, 3 Jun 2011 17:06:47 -0400 Subject: [PATCH] cc-2344: wrong song displayed -removed unnecessary code. --- airtime_mvc/application/models/Schedule.php | 8 -------- 1 file changed, 8 deletions(-) diff --git a/airtime_mvc/application/models/Schedule.php b/airtime_mvc/application/models/Schedule.php index 67c4d352e..4bc2fbbd2 100644 --- a/airtime_mvc/application/models/Schedule.php +++ b/airtime_mvc/application/models/Schedule.php @@ -397,13 +397,6 @@ class Schedule { public static function GetCurrentScheduleItem($p_timeNow, $p_instanceId){ global $CC_CONFIG, $CC_DBC; - /* Note that usually there will be one result returned. In some - * rare cases two songs are returned. This happens when a track - * that was overbooked from a previous show appears as if it - * hasnt ended yet (track end time hasn't been reached yet). For - * this reason, we need to get the track that starts later, as - * this is the *real* track that is currently playing. So this - * is why we are ordering by track start time. */ $sql = "SELECT *" ." FROM $CC_CONFIG[scheduleTable] st" ." LEFT JOIN $CC_CONFIG[filesTable] ft" @@ -411,7 +404,6 @@ class Schedule { ." WHERE st.starts <= TIMESTAMP '$p_timeNow'" ." AND st.instance_id = $p_instanceId" ." AND st.ends > TIMESTAMP '$p_timeNow'" - ." ORDER BY st.starts DESC" ." LIMIT 1"; $row = $CC_DBC->GetAll($sql);