Permalink
Browse files

Added a guard against invalid programs that start before the last pro…

…gram ended
  • Loading branch information...
1 parent 8a82159 commit 8aa362324b41adc6734ec24d133aceb134274f7b @fracmak committed Oct 22, 2011
Showing with 4 additions and 0 deletions.
  1. +4 −0 modules/tv/tmpl/default/list_data.php
@@ -61,6 +61,10 @@
$program_list = load_program_list($list_starttime, $list_endtime);
foreach ($program_list as $program) {
+ if ($last_chan_id == $program->chanid && $program->starttime < $program_ends){
+ //this is a guard against invalid programs that start before the last program ends
+ continue;
+ }
// Get a modified start/end time for this program (in case it starts/ends outside of the aloted time
$program_starts = $program->starttime;
$program_ends = $program->endtime;

0 comments on commit 8aa3623

Please sign in to comment.