diff --git a/src/fs/Walk_windows.go b/src/fs/Walk_windows.go index 37e284c..ab0b771 100644 --- a/src/fs/Walk_windows.go +++ b/src/fs/Walk_windows.go @@ -12,11 +12,13 @@ import ( // It doesn't distinguish between files and directories. func Walk(directory string, callBack func(string)) error { return filepath.WalkDir(directory, func(path string, d fs.DirEntry, err error) error { - if strings.HasPrefix(d.Name(), ".") { + fileName := d.Name() + + if strings.HasPrefix(fileName, ".") { return filepath.SkipDir } - callBack(path) + callBack(fileName) return nil }) }