From f6b90fd3342b4ed5991dac065d712e4c0fa23eeb Mon Sep 17 00:00:00 2001 From: rudolfkoenig <> Date: Tue, 24 Apr 2012 11:01:10 +0000 Subject: [PATCH] Fixing 0 status problem git-svn-id: https://svn.fhem.de/fhem/trunk@1482 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/webfrontend/pgm2/01_FHEMWEB.pm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/fhem/webfrontend/pgm2/01_FHEMWEB.pm b/fhem/webfrontend/pgm2/01_FHEMWEB.pm index f432a9102..beb9419e6 100755 --- a/fhem/webfrontend/pgm2/01_FHEMWEB.pm +++ b/fhem/webfrontend/pgm2/01_FHEMWEB.pm @@ -1000,10 +1000,11 @@ FW_fileList($) my ($dir,$re) = ($1, $2); return if(!$re); # note: this fails if the filenames of several FileLogs match the same regexp. - # This is the case e.g. fore + # This is the case e.g. for # /var/log/fhem/foo-%Y.log # /var/log/fhem/foo-%Y-%m-%d.log - # I do not fix it because this could easily be avoided by using a different naming. + # I do not fix it because this could easily be avoided by using a different + # naming. # BN 2012-04-22 $re =~ s/%./\.*/g; my @ret; @@ -1872,10 +1873,10 @@ FW_dev2image($) return $icon if(!$name || !$defs{$name}); my ($type, $state) = ($defs{$name}{TYPE}, $defs{$name}{STATE}); - return $icon if(!$type || !$state); + return $icon if(!$type || !defined($state)); $state =~ s/ .*//; # Want to be able to have icons for "on-for-timer xxx" - $icon = $FW_icons{$state} if($FW_icons{$state}); # on.png + $icon = $FW_icons{$state} if(defined($FW_icons{$state}));# on.png $icon = $FW_icons{$type} if($FW_icons{$type}); # FS20.png $icon = $FW_icons{"$type.$state"} if($FW_icons{"$type.$state"}); # FS20.on.png $icon = $FW_icons{$name} if($FW_icons{$name}); # lamp.png