on off checking should be more exakt now

git-svn-id: svn://svn.code.sf.net/p/fhem/code/trunk@2977 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig
2013-03-24 13:11:36 +00:00
parent feae069b14
commit 21b1687270

View File

@@ -2486,7 +2486,8 @@ FW_devState($$)
my $state = $defs{$d}{STATE};
$state = "" if(!defined($state));
$hasOnOff = ($allSets =~ m/\bon\b/ && $allSets =~ m/\boff\b/);
$hasOnOff = ($allSets =~ m/(^| )on( |$)/ &&
$allSets =~ m/(^| )off( |$)/);
my $txt = $state;
if(defined(AttrVal($d, "showtime", undef))) {
my $v = $defs{$d}{READINGS}{state}{TIME};