mirror of
https://github.com/mickael-kerjean/filestash.git
synced 2026-10-19 16:14:39 +00:00
fix (plg_backend_local): filter out symlink
This commit is contained in:
@@ -77,7 +77,13 @@ func (this Local) Ls(path string) ([]os.FileInfo, error) {
|
||||
f.Close()
|
||||
return nil, err
|
||||
}
|
||||
return files, f.Close()
|
||||
out := files[:0]
|
||||
for _, file := range files {
|
||||
if file.Mode().IsRegular() || file.IsDir() {
|
||||
out = append(out, file)
|
||||
}
|
||||
}
|
||||
return out, f.Close()
|
||||
}
|
||||
|
||||
func (this Local) Stat(path string) (os.FileInfo, error) {
|
||||
|
||||
Reference in New Issue
Block a user