2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-02-07 16:59:18 +00:00

33_readingsProxy.pm: try to decouple NOTIFYDEV update

git-svn-id: https://svn.fhem.de/fhem/trunk@13268 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
justme-1968 2017-01-29 12:14:14 +00:00
parent a359849f7a
commit 49c415655e

View File

@ -42,6 +42,17 @@ sub readingsProxy_Initialize($)
.$readingFnAttributes;
}
sub
readingsProxy_setNotfiyDev($)
{
my ($hash) = @_;
if( $hash->{DEVICE} ) {
notifyRegexpChanged($hash,"(global|".$hash->{DEVICE}.")");
} else {
notifyRegexpChanged($hash,'');
}
}
sub
readingsProxy_updateDevices($)
{
@ -67,11 +78,7 @@ readingsProxy_updateDevices($)
}
}
if( $hash->{DEVICE} ) {
notifyRegexpChanged($hash,"(global|".$hash->{DEVICE}.")");
} else {
notifyRegexpChanged($hash,'');
}
InternalTimer(gettimeofday(), "readingsProxy_setNotfiyDev", $hash);
$hash->{CONTENT} = \%list;
readingsProxy_update($hash, undef);