Add NAS gateway support (#5516)

This commit is contained in:
poornas
2018-02-20 12:21:12 -08:00
committed by kannappanr
parent 926e480156
commit 25107c2e11
21 changed files with 259 additions and 95 deletions

View File

@@ -291,7 +291,7 @@ func (xl xlObjects) GetBucketPolicy(bucket string) (policy.BucketAccessPolicy, e
// fetch bucket policy from cache.
bpolicy := xl.bucketPolicies.GetBucketPolicy(bucket)
if reflect.DeepEqual(bpolicy, emptyBucketPolicy) {
return readBucketPolicy(bucket, xl)
return ReadBucketPolicy(bucket, xl)
}
return bpolicy, nil
}
@@ -303,7 +303,7 @@ func (xl xlObjects) DeleteBucketPolicy(bucket string) error {
// RefreshBucketPolicy refreshes policy cache from disk
func (xl xlObjects) RefreshBucketPolicy(bucket string) error {
policy, err := readBucketPolicy(bucket, xl)
policy, err := ReadBucketPolicy(bucket, xl)
if err != nil {
if reflect.DeepEqual(policy, emptyBucketPolicy) {