mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-06 07:49:52 +03:00
don't check mqtt if not using
This commit is contained in:
@@ -125,13 +125,13 @@ void Mqtt::resubscribe() {
|
||||
|
||||
// Main MQTT loop - sends out top item on publish queue
|
||||
void Mqtt::loop() {
|
||||
queuecount_ = mqttClient_->queueSize();
|
||||
|
||||
// exit if MQTT is not enabled or if there is no network connection
|
||||
if (!connected()) {
|
||||
return;
|
||||
}
|
||||
|
||||
queuecount_ = mqttClient_->queueSize();
|
||||
|
||||
uint32_t currentMillis = uuid::get_uptime();
|
||||
|
||||
// send heartbeat
|
||||
|
||||
Reference in New Issue
Block a user