Skip to content

Commit

Permalink
Update zigbee2mqtt.class.php
Browse files Browse the repository at this point in the history
  • Loading branch information
directman66 committed Jan 13, 2019
1 parent 56c55da commit 1d7a50b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion modules/zigbee2mqtt/zigbee2mqtt.class.php
Expand Up @@ -374,7 +374,11 @@ function processMessage($path, $value) {
}
}

setGlobal($rec['LINKED_OBJECT'].'.'.$rec['LINKED_PROPERTY'], $value, array($this->name=>'0'));

if ($value=='ON') $newvalue=1;
if ($value=='OFF') $newvalue=0;

setGlobal($rec['LINKED_OBJECT'].'.'.$rec['LINKED_PROPERTY'], $newvalue, array($this->name=>'0'));
}
if ($rec['LINKED_OBJECT'] && $cmd_rec['LINKED_METHOD']) {
callMethod($rec['LINKED_OBJECT'] . '.' . $rec['LINKED_METHOD'], $rec['VALUE']);
Expand Down

0 comments on commit 1d7a50b

Please sign in to comment.