Skip to content

Commit

Permalink
FIX: binary backlight_mode
Browse files Browse the repository at this point in the history
  • Loading branch information
Burki24 committed Feb 26, 2024
1 parent dcc9e89 commit c345aa3
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions libs/Zigbee2MQTTHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -4866,10 +4866,6 @@ private function mapExposesToVariables(array $exposes)
switch ($feature['type']) {
case 'binary':
switch ($feature['property']) {
case 'backlight_mode':
$this->RegisterVariableBoolean('Z2M_BacklightMode', $this->Translate('Backlight Mode'), '~Switch');
$this->EnableAction('Z2M_BacklightMode');
break;
case 'learn_ir_code':
$this->RegisterVariableBoolean('Z2M_LearnIRCode', $this->Translate('Learn IR Code'), '~Switch');
$this->EnableAction('Z2M_LearnIRCode');
Expand Down Expand Up @@ -5350,10 +5346,8 @@ private function mapExposesToVariables(array $exposes)
case 'binary':
switch ($expose['property']) {
case 'backlight_mode':
if ($ProfileName != false) {
$this->RegisterVariableBoolean('Z2M_BacklightMode', $this->Translate('Backlight Mode'), $ProfileName);
$this->EnableAction('Z2M_BacklightMode');
}
$this->RegisterVariableBoolean('Z2M_BacklightMode', $this->Translate('Backlight Mode'), '~Switch');
$this->EnableAction('Z2M_BacklightMode');
break;
case 'online':
$this->RegisterVariableBoolean('Z2M_Online', $this->Translate('Online'), '~Switch');
Expand Down

0 comments on commit c345aa3

Please sign in to comment.