From 62aed27ba77272d7bbac9ec7210a5e81fdb23df7 Mon Sep 17 00:00:00 2001 From: rudolfkoenig <> Date: Sun, 17 Apr 2016 11:19:15 +0000 Subject: [PATCH] 92_FileLog.pm: do not convert min/max values to "undef" (Forum #52031) git-svn-id: https://svn.fhem.de/fhem/trunk@11265 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/FHEM/92_FileLog.pm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/fhem/FHEM/92_FileLog.pm b/fhem/FHEM/92_FileLog.pm index 18d24c87e..929d12f91 100755 --- a/fhem/FHEM/92_FileLog.pm +++ b/fhem/FHEM/92_FileLog.pm @@ -874,11 +874,11 @@ RESCAN: } my $j = $i+1; - $data{"min$j"} = $min[$i] == 999999 ? "undef" : $min[$i]; - $data{"max$j"} = $max[$i] == -999999 ? "undef" : $max[$i]; - $data{"avg$j"} = $cnt[$i] ? sprintf("%0.1f", $sum[$i]/$cnt[$i]) : "undef"; + $data{"min$j"} = $min[$i]; + $data{"max$j"} = $max[$i]; + $data{"avg$j"} = $cnt[$i] ? sprintf("%0.1f", $sum[$i]/$cnt[$i]) : 0; $data{"sum$j"} = $sum[$i]; - $data{"cnt$j"} = $cnt[$i] ? $cnt[$i] : "undef"; + $data{"cnt$j"} = $cnt[$i]; $data{"currval$j"} = $lastv[$i]; $data{"currdate$j"} = $lastd[$i]; $data{"firstval$j"} = $firstv[$i];