Skip to content

Commit

Permalink
Update 88_Timer.pm
Browse files Browse the repository at this point in the history
- fix, incorrect monthly calculation on return
  • Loading branch information
HomeAutoUser committed Jan 4, 2022
1 parent 7dc6fc4 commit 0664052
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion FHEM/88_Timer.pm
Original file line number Diff line number Diff line change
Expand Up @@ -850,7 +850,7 @@ sub FW_pushed_savebutton {
}

if ((time() - fhemTimeLocal($sec, $min, $hour, $mday, $month, $year)) > 0) { return 'ERROR: The time is in the past. Please set a time in the future!'; }
if ((fhemTimeLocal($sec, $min, $hour, $mday, $month - 1, $year) - time()) < 60) { return 'ERROR: The next switching point is too small!'; }
if ((fhemTimeLocal($sec, $min, $hour, $mday, $month, $year) - time()) < 60) { return 'ERROR: The next switching point is too small!'; }

my $oldValue = ReadingsVal($name,'Timer_'.sprintf("%02s", $selected_buttons[0]) ,0);
my $newValue = substr($selected_buttons,(index($selected_buttons,',') + 1));
Expand Down

0 comments on commit 0664052

Please sign in to comment.