diff --git a/src/publisher/pubMqtt.h b/src/publisher/pubMqtt.h index f9bf6f4d..40ea1753 100644 --- a/src/publisher/pubMqtt.h +++ b/src/publisher/pubMqtt.h @@ -8,6 +8,8 @@ #ifndef __PUB_MQTT_H__ #define __PUB_MQTT_H__ +#ifdef AHOY_MQTT_SUPPORT + #ifdef ESP8266 #include #elif defined(ESP32) @@ -675,5 +677,6 @@ class PubMqtt { char mVal[40]; discovery_t mDiscovery; }; +#endif #endif /*__PUB_MQTT_H__*/ diff --git a/src/publisher/pubMqttDefs.h b/src/publisher/pubMqttDefs.h index 088023b7..869243ea 100644 --- a/src/publisher/pubMqttDefs.h +++ b/src/publisher/pubMqttDefs.h @@ -6,6 +6,8 @@ #ifndef __PUB_MQTT_DEFS_H__ #define __PUB_MQTT_DEFS_H__ +#ifdef AHOY_MQTT_SUPPORT + #include enum { @@ -92,5 +94,6 @@ enum { const char* const subscr[] PROGMEM = { "setup/set_time" }; +#endif #endif /*__PUB_MQTT_DEFS_H__*/