do no touch STATE if neither the state reading nor the stateFormat attribute exist

git-svn-id: svn://svn.code.sf.net/p/fhem/code/trunk@2436 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
borisneubert
2013-01-04 19:38:41 +00:00
parent 4221e1f984
commit 9e523df436

View File

@@ -2964,7 +2964,7 @@ readingsEndUpdate($$)
$st =~ s/\b([A-Za-z_-]+)\b/($r->{$1} ? $r->{$1}{VAL} : $1)/ge;
}
$hash->{STATE} = ReplaceEventMap($name, $st, 1);
$hash->{STATE} = ReplaceEventMap($name, $st, 1) if(defined($st));
# propagate changes