Skip to content

Commit

Permalink
return us-east-1 when endpoint is cloudflare (#1651)
Browse files Browse the repository at this point in the history
  • Loading branch information
harshavardhana authored May 12, 2022
1 parent 446decb commit e765365
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion bucket-cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,11 @@ func processBucketLocationResponse(resp *http.Response, bucketName string) (buck
// succeed if possible based on their policy.
switch errResp.Code {
case "NotImplemented":
if errResp.Server == "AmazonSnowball" {
switch errResp.Server {
case "AmazonSnowball":
return "snowball", nil
case "cloudflare":
return "us-east-1", nil
}
case "AuthorizationHeaderMalformed":
fallthrough
Expand Down

0 comments on commit e765365

Please sign in to comment.