handleFileRead: Skip duplicate FS check

Since we validate the file existence ourselves, no need to have
AsyncWebServer do it again.
This commit is contained in:
Will Miles 2024-09-07 19:51:23 -04:00
parent 72455ccde1
commit d4268ba070

View File

@ -433,7 +433,7 @@ bool handleFileRead(AsyncWebServerRequest* request, String path){
}
#endif
if(WLED_FS.exists(path) || WLED_FS.exists(path + ".gz")) {
request->send(WLED_FS, path, String(), request->hasArg(F("download")));
request->send(request->beginResponse(WLED_FS, path, {}, request->hasArg(F("download")), {}));
return true;
}
return false;