Fix client-s3.Makebucket behavior with object in path (#3470)
This commit is contained in:
+1
-4
@@ -1196,10 +1196,7 @@ func (c *S3Client) MakeBucket(ctx context.Context, region string, ignoreExisting
|
||||
}
|
||||
if object != "" {
|
||||
if !strings.HasSuffix(object, string(c.targetURL.Separator)) {
|
||||
object = path.Dir(object)
|
||||
}
|
||||
if !strings.HasSuffix(object, string(c.targetURL.Separator)) {
|
||||
return probe.NewError(BucketNameTopLevel{})
|
||||
object += string(c.targetURL.Separator)
|
||||
}
|
||||
var retried bool
|
||||
for {
|
||||
|
||||
Reference in New Issue
Block a user