mirror of
https://github.com/esp8266/Arduino.git
synced 2025-04-21 10:26:06 +03:00
Improve LittleFS support (#7071)
Previously, when the path was a directory, but didn't have a slash at the end, a 0 byte response would be sent when using LittleFS. Now, it will return a 404, like was always the case when using SPIFFS.
This commit is contained in:
parent
16319da63d
commit
d990ff9547
@ -134,6 +134,11 @@ public:
|
|||||||
if (!f)
|
if (!f)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
if (!f.isFile()) {
|
||||||
|
f.close();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (_cache_header.length() != 0)
|
if (_cache_header.length() != 0)
|
||||||
server.sendHeader("Cache-Control", _cache_header);
|
server.sendHeader("Cache-Control", _cache_header);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user