mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-05-04 22:19:38 +00:00
38_BEOK.pm: fix regex for set profile time and temp
git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@24803 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
3bc2f684db
commit
0f070c5d65
@ -519,8 +519,8 @@ sub Set {
|
||||
return send_packet($hash, 0x6a, @payload);
|
||||
}
|
||||
|
||||
if ( $cmd =~ m{ /^(day|we)-profile[1-8]-time$/ }x ) {
|
||||
return "Time must be between 0:00 and 23:59" if ($subcmd !~ m{/(?:[01]\d|2[0123]):(?:[012345]\d)/gm}x);
|
||||
if ( $cmd =~ m{(day|we)-profile[1-8]-time}x ) {
|
||||
return "Time must be between 0:00 and 23:59" if ($subcmd !~ /(?:[01]\d|2[0123]):(?:[012345]\d)/gmx);
|
||||
my $day = $cmd;
|
||||
$day =~ s/(day|we)-profile//;
|
||||
$day =~ s/-time//;
|
||||
@ -534,7 +534,7 @@ sub Set {
|
||||
return send_packet($hash, 0x6a, @payload);
|
||||
}
|
||||
|
||||
if ( $cmd =~ m{ /^(day|we)-profile[1-8]-temp$/ }x ) {
|
||||
if ( $cmd =~ m{(day|we)-profile[1-8]-temp}x ) {
|
||||
my $temp = int($subcmd*2);
|
||||
return "Temperature must be between 5 and 99" if (($temp < 10) || ($temp > 198));
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user