[mythtv-commits] Ticket #10142: Prevent PHP warning in upcoming.php due to wrong datatype in foreach

MythTV noreply at mythtv.org
Mon Oct 31 10:37:52 UTC 2011


#10142: Prevent PHP warning in upcoming.php due to wrong datatype in foreach
-------------------------------------------------+-------------------------
     Reporter:  Philipp Wagner <mail@…>          |      Owner:  kormoc
         Type:  Patch - Bug Fix                  |     Status:  new
     Priority:  minor                            |  Milestone:  unknown
    Component:  Plugin - MythWeb                 |    Version:  Trunk Head
     Severity:  medium                           |   Keywords:
Ticket locked:  0                                |
-------------------------------------------------+-------------------------
 At /tv/upcoming I get the following PHP warning:

 ----------
 Warning at /usr/share/mythtv/mythweb/modules/tv/upcoming.php, line 96:
 !!NoTrans: Invalid argument supplied for foreach()!!

 Warning at
 /usr/share/mythtv/mythweb/modules/_shared/tmpl/default/header.php, line
 16:
 !!NoTrans: Cannot modify header information - headers already sent by
 (output started at /usr/share/mythtv/mythweb/includes/errors.php:150)!!
 ----------

 It seems that the code tried to prevent that, but somehow it didn't get a
 full fix ($scheduled is unused). Trivial patch attached.

 I am running 0.24.1 here, but it seems that the code is the same in the
 git master.

-- 
Ticket URL: <http://code.mythtv.org/trac/ticket/10142>
MythTV <http://code.mythtv.org/trac>
MythTV Media Center


More information about the mythtv-commits mailing list