mirror of
https://github.com/minio/minio.git
synced 2025-03-31 17:53:43 -04:00
do not attempt force delete on bucket (#14452)
caller needs to ask explicitly for force delete otherwise, the force delete might end up deleting an existing bucket with data. fixes #14445
This commit is contained in:
parent
5b5deee5b3
commit
7e803adf13
@ -671,7 +671,9 @@ func (z *erasureServerPools) MakeBucketWithLocation(ctx context.Context, bucket
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
if _, ok := err.(BucketExists); !ok {
|
if _, ok := err.(BucketExists); !ok {
|
||||||
// Delete created buckets, ignoring errors.
|
// Delete created buckets, ignoring errors.
|
||||||
z.DeleteBucket(context.Background(), bucket, DeleteBucketOptions{Force: true, NoRecreate: true})
|
z.DeleteBucket(context.Background(), bucket, DeleteBucketOptions{
|
||||||
|
Force: false, NoRecreate: true,
|
||||||
|
})
|
||||||
}
|
}
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user