Fix bug on rule variable %topic%

This commit is contained in:
Adrian Scillato 2020-06-19 02:12:05 -03:00 committed by GitHub
parent 47c27481f2
commit 09871f8668
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -711,7 +711,7 @@ bool RuleSetProcess(uint8_t rule_set, String &event_saved)
RulesVarReplace(commands, F("%UTCTIME%"), String(UtcTime()));
RulesVarReplace(commands, F("%UPTIME%"), String(MinutesUptime()));
RulesVarReplace(commands, F("%TIMESTAMP%"), GetDateAndTime(DT_LOCAL));
RulesVarReplace(commands, F("%TOPIC%"), SettingsText(SET_MQTT_TOPIC));
RulesVarReplace(commands, F("%TOPIC%"), mqtt_topic);
#if defined(USE_TIMERS) && defined(USE_SUNRISE)
RulesVarReplace(commands, F("%SUNRISE%"), String(SunMinutes(0)));
RulesVarReplace(commands, F("%SUNSET%"), String(SunMinutes(1)));