Skip to content

Commit

Permalink
Bugfix (Aircoookie#3533)
Browse files Browse the repository at this point in the history
  • Loading branch information
blazoncek authored and softhack007 committed Nov 27, 2023
1 parent bd889a4 commit 79319d4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions wled00/presets.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -290,9 +290,9 @@ void savePreset(byte index, const char* pname, JsonObject sObj)
playlistSave = false;
if (sObj[F("ql")].is<const char*>()) strlcpy(quickLoad, sObj[F("ql")].as<const char*>(), 9); // client limits QL to 2 chars, buffer for 8 bytes to allow unicode

if (sObj["o"].isNull()) { // no "o" means not a playlist or custom API call, saving of state is async (not immediately)
includeBri = sObj["ib"].as<bool>() || index==255; // temporary preset needs brightness
segBounds = sObj["sb"].as<bool>() || index==255; // temporary preset needs bounds
if (sObj.size()==0 || sObj["o"].isNull()) { // no "o" means not a playlist or custom API call, saving of state is async (not immediately)
includeBri = sObj["ib"].as<bool>() || sObj.size()==0 || index==255; // temporary preset needs brightness
segBounds = sObj["sb"].as<bool>() || sObj.size()==0 || index==255; // temporary preset needs bounds
selectedOnly = sObj[F("sc")].as<bool>();
saveLedmap = sObj[F("ledmap")] | -1;
} else {
Expand Down

0 comments on commit 79319d4

Please sign in to comment.