Fix write with string
This commit is contained in:
parent
649ebb8a4e
commit
6ef4582ebd
@ -166,7 +166,7 @@ bool appendObjectToFile(const char* file, const char* key, JsonDocument* content
|
|||||||
Serial.print("clen"); Serial.println(contentLen);
|
Serial.print("clen"); Serial.println(contentLen);
|
||||||
if (bufferedFindSpace(contentLen + strlen(key) + 1, f)) {
|
if (bufferedFindSpace(contentLen + strlen(key) + 1, f)) {
|
||||||
Serial.println("space");
|
Serial.println("space");
|
||||||
if (f.position() > 2) f.write(","); //add comma if not first object
|
if (f.position() > 2) f.write(','); //add comma if not first object
|
||||||
f.print(key);
|
f.print(key);
|
||||||
serializeJson(*content, f);
|
serializeJson(*content, f);
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user