Version 1.42

Fixed bug with ESP-NOW devices not getting restart or update command.
Minor main code refactoring.
This commit is contained in:
Alexey Zholtikov 2023-02-13 18:56:39 +03:00
parent 57d0bc6481
commit e4572cc31a

View File

@ -403,7 +403,6 @@ void onMqttMessage(char *topic, byte *payload, unsigned int length)
esp_now_payload_data_t outgoingData;
outgoingData.deviceType = ENDT_GATEWAY;
StaticJsonDocument<sizeof(esp_now_payload_data_t::message)> json;
mqttPublish((topicPrefix + "/test").c_str(), String(message).c_str(), true);
if (message == "update" || message == "restart")
{
if (mac == myNet.getNodeMac() && message == "restart")