Skip to content

Commit

Permalink
Fix in settings
Browse files Browse the repository at this point in the history
  • Loading branch information
ropg committed Feb 19, 2024
1 parent 6eddf30 commit 28aff9c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/Settings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ bool Settings::rm(const String filename) {
return false;
}
if (SPIFFS.remove(actual_filename)) {
INFO("File '%s' deleted.\r\n", filename.c_str());
INFO("File '%s' deleted.\n", filename.c_str());
return true;
}
ERROR("ERROR: rm '%s': file not found.\n", filename);
Expand Down Expand Up @@ -127,9 +127,11 @@ bool Settings::fromList(String in) {
break;
}
String this_one = in.substring(0, lf);
int equals_sign = in.indexOf("=");
int equals_sign = this_one.indexOf("=");
if (equals_sign != -1) {
store[this_one.substring(0, equals_sign)] = this_one.substring(equals_sign + 1);
} else {
store[this_one.substring(0, equals_sign)] = "";
}
in = in.substring(lf + 1);
}
Expand Down

0 comments on commit 28aff9c

Please sign in to comment.