seaweedfs/weed/filer/filer_buckets.go

22 lines
301 B
Go
Raw Normal View History

2020-09-01 15:21:19 +08:00
package filer
import (
"strings"
)
func (f *Filer) isBucket(entry *Entry) bool {
if !entry.IsDirectory() {
return false
}
parent, dirName := entry.FullPath.DirAndName()
if parent != f.DirBucketsPath {
return false
}
if strings.HasPrefix(dirName, ".") {
return false
}
return true
}