From b97b6dc144207bce7d41392c0c198b25c59f3558 Mon Sep 17 00:00:00 2001 From: cschwinne Date: Tue, 23 Nov 2021 13:17:33 +0100 Subject: [PATCH] Remove F macro for "ps" --- wled00/cfg.cpp | 4 ++-- wled00/json.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/wled00/cfg.cpp b/wled00/cfg.cpp index 20bcdbd89..a72af85bb 100644 --- a/wled00/cfg.cpp +++ b/wled00/cfg.cpp @@ -220,7 +220,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { CJSON(macroNl, light_nl["macro"]); JsonObject def = doc[F("def")]; - CJSON(bootPreset, def[F("ps")]); + CJSON(bootPreset, def["ps"]); CJSON(turnOnAtBoot, def["on"]); // true CJSON(briS, def["bri"]); // 128 @@ -593,7 +593,7 @@ void serializeConfig() { light_nl["macro"] = macroNl; JsonObject def = doc.createNestedObject("def"); - def[F("ps")] = bootPreset; + def["ps"] = bootPreset; def["on"] = turnOnAtBoot; def["bri"] = briS; diff --git a/wled00/json.cpp b/wled00/json.cpp index de40f5610..1a546c795 100644 --- a/wled00/json.cpp +++ b/wled00/json.cpp @@ -429,7 +429,7 @@ void serializeState(JsonObject root, bool forPreset, bool includeBri, bool segme if (!forPreset) { if (errorFlag) root[F("error")] = errorFlag; - root[F("ps")] = (currentPreset > 0) ? currentPreset : -1; + root["ps"] = (currentPreset > 0) ? currentPreset : -1; root[F("pl")] = currentPlaylist; usermods.addToJsonState(root);