mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-07 00:09:51 +03:00
incorporated Michael's changes https://github.com/emsesp/EMS-ESP32/pull/2027
This commit is contained in:
@@ -245,7 +245,7 @@ void WebSchedulerService::publish(const bool force) {
|
||||
JsonDocument doc;
|
||||
bool ha_created = ha_registered_;
|
||||
for (const ScheduleItem & scheduleItem : *scheduleItems_) {
|
||||
if (!scheduleItem.name.empty() && !doc[scheduleItem.name].is<const char *>()) {
|
||||
if (!scheduleItem.name.empty() && !doc[scheduleItem.name].is<JsonVariantConst>()) {
|
||||
if (EMSESP::system_.bool_format() == BOOL_FORMAT_TRUEFALSE) {
|
||||
doc[scheduleItem.name] = scheduleItem.active;
|
||||
} else if (EMSESP::system_.bool_format() == BOOL_FORMAT_10) {
|
||||
|
||||
Reference in New Issue
Block a user