|
@ -328,8 +328,6 @@ void _mqttConfigure() { |
|
|
|
|
|
|
|
|
if (topic.indexOf("#") == -1) topic.concat("/#"); |
|
|
if (topic.indexOf("#") == -1) topic.concat("/#"); |
|
|
_mqttApplySetting(_mqtt_topic, topic); |
|
|
_mqttApplySetting(_mqtt_topic, topic); |
|
|
|
|
|
|
|
|
_mqttApplyTopic(_mqtt_will, MQTT_TOPIC_STATUS); |
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// Getter and setter
|
|
|
// Getter and setter
|
|
@ -365,6 +363,11 @@ void _mqttConfigure() { |
|
|
_mqttApplySetting(_mqtt_clientid, id); |
|
|
_mqttApplySetting(_mqtt_clientid, id); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// MQTT WILL
|
|
|
|
|
|
{ |
|
|
|
|
|
_mqttApplyTopic(_mqtt_will, MQTT_TOPIC_STATUS); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
// MQTT JSON
|
|
|
// MQTT JSON
|
|
|
{ |
|
|
{ |
|
|
_mqttApplySetting(_mqtt_use_json, getSetting("mqttUseJson", MQTT_USE_JSON).toInt() == 1); |
|
|
_mqttApplySetting(_mqtt_use_json, getSetting("mqttUseJson", MQTT_USE_JSON).toInt() == 1); |
|
|