2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-03-10 09:16:53 +00:00

93_DbRep: fix Perl warning

git-svn-id: https://svn.fhem.de/fhem/trunk@21169 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
nasseeder1 2020-02-10 21:15:23 +00:00
parent c16e1715aa
commit 7fbcdcaff3
2 changed files with 3 additions and 1 deletions

View File

@ -1,5 +1,6 @@
# Add changes at the top of the list. Keep it in ASCII, and 80-char wide.
# Do not insert empty lines here, update check depends on it.
- bugfix: 93_DbRep: fix Perl warning
- feature: 70_DENON_AVR: added more surround modes (thx Shadow3561)
- bugfix: 70_Pushsafer: fix availableMessages reading
- bugfix: 73_AutoShuttersControl: fix GetAntiFreez

View File

@ -58,6 +58,7 @@ no if $] >= 5.017011, warnings => 'experimental::smartmatch';
# Version History intern
our %DbRep_vNotesIntern = (
"8.32.1" => "08.02.2020 fix PERL WARNING: Argument \"\" isn't numeric in sprintf at ./FHEM/93_DbRep.pm line 10708 ",
"8.32.0" => "29.01.2020 new option \"deleteOther\" for minValue ",
"8.31.0" => "26.01.2020 new option \"deleteOther\" for maxValue ",
"8.30.8" => "25.01.2020 adjust SQL-Statements in OutputWriteToDB to avoid Duplicate entry errors and other fixes ",
@ -10705,7 +10706,7 @@ sub DbRep_OutputWriteToDB($$$$$) {
foreach my $row (@arr) {
my @a = split("#", $row);
my $runtime_string = $a[0]; # Aggregations-Alias (nicht benötigt)
$value = defined($a[1])?sprintf("%.4f",$a[1]):undef;
$value = looks_like_number($a[1])?sprintf("%.4f",$a[1]):undef;
$rsf = $a[2]; # Runtime String first - Datum / Zeit für DB-Speicherung
($date,$time) = split("_",$rsf);
$time =~ s/-/:/g if($time);