From 56b8096beddf6ec20012de9be8c2b5e91eb8ed1c Mon Sep 17 00:00:00 2001 From: lumapu Date: Tue, 1 Nov 2022 01:22:39 +0100 Subject: [PATCH] updated mqtt counter --- tools/esp8266/mqtt.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/esp8266/mqtt.h b/tools/esp8266/mqtt.h index 6f6e997e..1d687d77 100644 --- a/tools/esp8266/mqtt.h +++ b/tools/esp8266/mqtt.h @@ -53,7 +53,6 @@ class mqtt { char top[64]; snprintf(top, 64, "%s/%s", mCfg->topic, topic); sendMsg2(top, msg, false); - mTxCnt++; } void sendMsg2(const char *topic, const char *msg, boolean retained) { @@ -63,6 +62,7 @@ class mqtt { if(mClient->connected()) mClient->publish(topic, msg, retained); } + mTxCnt++; } bool isConnected(bool doRecon = false) {