mirror of
https://github.com/minio/minio.git
synced 2024-12-26 23:25:54 -05:00
Skip policy files
This commit is contained in:
parent
4ce180bb72
commit
f04beab7c2
@ -66,6 +66,10 @@ func (storage *storage) ListBuckets() ([]mstorage.BucketMetadata, error) {
|
|||||||
|
|
||||||
var metadataList []mstorage.BucketMetadata
|
var metadataList []mstorage.BucketMetadata
|
||||||
for _, file := range files {
|
for _, file := range files {
|
||||||
|
// Skip policy files
|
||||||
|
if strings.HasSuffix(file.Name(), "_policy.json") {
|
||||||
|
continue
|
||||||
|
}
|
||||||
if !file.IsDir() {
|
if !file.IsDir() {
|
||||||
return []mstorage.BucketMetadata{}, mstorage.BackendCorrupted{Path: storage.root}
|
return []mstorage.BucketMetadata{}, mstorage.BackendCorrupted{Path: storage.root}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user