fix: address code review findings
This commit is contained in:
@@ -277,10 +277,10 @@ func isRetryableError(err error) bool {
|
||||
if err == nil {
|
||||
return false
|
||||
}
|
||||
// Check for HTTP status codes that are retryable (5xx errors)
|
||||
// Check for HTTP status codes that are retryable (5xx errors and 429)
|
||||
apiErr, ok := err.(*APIError)
|
||||
if ok {
|
||||
return apiErr.Code >= 500 && apiErr.Code < 600
|
||||
return (apiErr.Code >= 500 && apiErr.Code < 600) || apiErr.Code == 429
|
||||
}
|
||||
// Check for network errors
|
||||
errStr := err.Error()
|
||||
|
||||
Reference in New Issue
Block a user