Browse Source

Fix unused vars

As codacy points out, move stype and switchType to the LIGHT_PROVIDER != NONE block
mcspr-patch-1
Max Prokhorov 4 years ago
committed by GitHub
parent
commit
b718636ecc
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      code/espurna/domoticz.cpp

+ 2
- 2
code/espurna/domoticz.cpp View File

@ -153,10 +153,10 @@ void _domoticzMqtt(unsigned int type, const char * topic, char * payload) {
// IDX
unsigned int idx = root["idx"];
String stype = root["stype"];
String switchType = root["switchType"];
#if LIGHT_PROVIDER != LIGHT_PROVIDER_NONE
String stype = root["stype"];
String switchType = root["switchType"];
if ((_domoticzIdx(0) == idx) && (stype.startsWith("RGB") || (switchType.equals("Dimmer")))) {
_domoticzLight(idx, root);
}


Loading…
Cancel
Save