fixed api, fixed ListFiles function

This commit is contained in:
yusing
2024-10-02 17:34:35 +08:00
parent ed9d8aab6f
commit ef52ccb929
8 changed files with 62 additions and 51 deletions

View File

@@ -23,9 +23,7 @@ func ListFiles(dir string, maxDepth int) ([]string, error) {
if err != nil {
return nil, err
}
for _, subEntry := range subEntries {
files = append(files, path.Join(dir, entry.Name(), subEntry))
}
files = append(files, subEntries...)
} else {
files = append(files, path.Join(dir, entry.Name()))
}