homieiot / homie-esp8266

💡 ESP8266 framework for Homie, a lightweight MQTT convention for the IoT
http://homieiot.github.io/homie-esp8266
MIT License
1.36k stars 307 forks source link

Little fix for DEBUG build flag #713

Closed elbowz closed 3 years ago

elbowz commented 3 years ago

Activating DEBUG build flag I get the error:

.pio/libdeps/nodemcuv2/Homie/src/Homie/Boot/BootNormal.cpp: In member function 'bool HomieInternals::BootNormal::__handleNodeProperty(char*, char*, const AsyncMqttClientMessageProperties&, size_t, size_t, size_t)':
.pio/libdeps/nodemcuv2/Homie/src/Homie/Boot/BootNormal.cpp:1117:74: error: 'homieNode' was not declared in this scope
     Interface::get().getLogger() << F("Recived network message for ") << homieNode->getId() << endl;

Simply move the block: https://github.com/homieiot/homie-esp8266/blob/9cd83972f27b394eab8a5e3e2baef20eea1b5408/src/Homie/Boot/BootNormal.cpp#L1125-L1127

under: https://github.com/homieiot/homie-esp8266/blob/9cd83972f27b394eab8a5e3e2baef20eea1b5408/src/Homie/Boot/BootNormal.cpp#L1151

or viceversa.

Always thanks for this wonderful project!

elbowz commented 3 years ago

Fixed with #719