simplify bucket metadata lookups for versioning/object locking (#17253)

This commit is contained in:
Harshavardhana
2023-05-22 12:05:14 -07:00
committed by GitHub
parent b1b00a5055
commit fc03be7891
5 changed files with 21 additions and 8 deletions

View File

@@ -705,7 +705,7 @@ func (a adminAPIHandlers) ImportBucketMetadataHandler(w http.ResponseWriter, r *
}
if _, ok := bucketMap[bucket]; !ok {
opts := MakeBucketOptions{
LockEnabled: config.ObjectLockEnabled == "Enabled",
LockEnabled: config.Enabled(),
}
err = objectAPI.MakeBucket(ctx, bucket, opts)
if err != nil {