Skip to content

Commit

Permalink
[bugfix] retry on http 500 errors *inclusive* (#2886)
Browse files Browse the repository at this point in the history
  • Loading branch information
NyaaaWhatsUpDoc committed Apr 30, 2024
1 parent ec334ec commit ec7c983
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/httpclient/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,7 @@ func (c *Client) do(r *Request) (rsp *http.Response, retry bool, err error) {
// A retryable error.
return nil, true, err

} else if rsp.StatusCode > 500 ||
} else if rsp.StatusCode >= 500 ||
rsp.StatusCode == http.StatusTooManyRequests {

// Codes over 500 (and 429: too many requests)
Expand Down

0 comments on commit ec7c983

Please sign in to comment.