Skip to content

Commit beb1142

Browse files
Add SDFS::Dir::fileTime callback
Forgot to add a Dir->fileTime override, resulting in it always returning (time_t)0, or Jan 1, 1970. Add the override, returning the proper lastWriteTime. Fixes esp8266#6981
1 parent b62d8c7 commit beb1142

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

libraries/SDFS/src/SDFS.h

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -417,6 +417,16 @@ class SDFSDirImpl : public DirImpl
417417
return _size;
418418
}
419419

420+
time_t fileTime() override
421+
{
422+
if (!_valid) {
423+
return 0;
424+
}
425+
426+
return _time;
427+
}
428+
429+
420430
bool isFile() const override
421431
{
422432
return _valid ? _isFile : false;

0 commit comments

Comments
 (0)