mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-07 16:29:51 +03:00
json optimizations
This commit is contained in:
@@ -109,6 +109,7 @@ void EMSESPAPIService::emsespAPIService(AsyncWebServerRequest * request) {
|
|||||||
|
|
||||||
// if we have returned data in JSON format, send this to the WEB
|
// if we have returned data in JSON format, send this to the WEB
|
||||||
if (output.size()) {
|
if (output.size()) {
|
||||||
|
doc.shrinkToFit();
|
||||||
char buffer[EMSESP_MAX_JSON_SIZE_LARGE];
|
char buffer[EMSESP_MAX_JSON_SIZE_LARGE];
|
||||||
serializeJson(doc, buffer);
|
serializeJson(doc, buffer);
|
||||||
request->send(200, "text/plain", buffer);
|
request->send(200, "text/plain", buffer);
|
||||||
|
|||||||
Reference in New Issue
Block a user