diff --git a/fhem/CHANGED b/fhem/CHANGED index 559bfca0a..18c436934 100644 --- a/fhem/CHANGED +++ b/fhem/CHANGED @@ -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: 79_Klafs: minor bugfix for date format - bugfix: 38_netatmo: fixed csrf error on home notification settings - bugfix: 10_SOMFY: Correct match for long commands according to #msg1224029 - bugfix: 70_Klafs: Start time error fixed diff --git a/fhem/FHEM/70_Klafs.pm b/fhem/FHEM/70_Klafs.pm index 61feb8212..23d9457b0 100644 --- a/fhem/FHEM/70_Klafs.pm +++ b/fhem/FHEM/70_Klafs.pm @@ -32,7 +32,7 @@ use JSON qw(decode_json encode_json); #use Encode qw(encode_utf8 decode_utf8); use Time::Piece; use Time::Local; -use Data::Dumper; +#use Data::Dumper; use HttpUtils; use FHEM::Core::Authentication::Passwords qw(:ALL); @@ -666,11 +666,19 @@ sub Klafs_Set { $now += $FIFTEEN_MINS - $diff; } my $next = scalar localtime $now; + # doppelte Leerzeichen bei einstelligen Datumsangaben entfernen + $next =~ tr/ //s; my @Zeit = split(/ /,$next); - my @Uhrzeit = split(/:/,$Zeit[4]); + my @Uhrzeit = split(/:/,$Zeit[3]); my $std = $Uhrzeit[0]; my $min = $Uhrzeit[1]; - + # print "Decoded Zeit:\n".Dumper(@Zeit); + #Decoded Zeit: + #$VAR1 = 'Mon'; + #$VAR2 = 'Jun'; + #$VAR3 = '20'; + #$VAR4 = '15:15:00'; + #$VAR5 = '2022'; if($std < 10){ if(substr($std,0,1) eq "0"){