Migrate to LittleFS under ESP8266
Make ESP8266 use LittleFS instead of deprecated SPIFFS Make framework use the correct filesystem automatically and handle the call the FS.begin() Change default MQTT keepalive to 60 seconds Fix lodash security issue
This commit is contained in:
@ -31,11 +31,11 @@ void SystemStatus::systemStatus(AsyncWebServerRequest* request) {
|
||||
// TODO - Ideally this class will take an *FS and extract the file system information from there.
|
||||
// ESP8266 and ESP32 do not have feature parity in FS.h which currently makes that difficult.
|
||||
#ifdef ESP32
|
||||
root["fs_total"] = SPIFFS.totalBytes();
|
||||
root["fs_used"] = SPIFFS.usedBytes();
|
||||
root["fs_total"] = ESPFS.totalBytes();
|
||||
root["fs_used"] = ESPFS.usedBytes();
|
||||
#elif defined(ESP8266)
|
||||
FSInfo fs_info;
|
||||
SPIFFS.info(fs_info);
|
||||
ESPFS.info(fs_info);
|
||||
root["fs_total"] = fs_info.totalBytes;
|
||||
root["fs_used"] = fs_info.usedBytes;
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user