diff --git a/hugofs/filter_fs.go b/hugofs/filter_fs.go index ca9c333614f..15373c2e552 100644 --- a/hugofs/filter_fs.go +++ b/hugofs/filter_fs.go @@ -153,7 +153,8 @@ func (fs *FilterFs) LstatIfPossible(name string) (os.FileInfo, bool, error) { return decorateFileInfo(fi, fs, fs.getOpener(name), "", "", nil), false, nil } - fs.applyFilters(name, -1, fi) + parent := filepath.Dir(name) + fs.applyFilters(parent, -1, fi) return fi, b, nil