(responseDump []byte)
| 58 | } |
| 59 | |
| 60 | func providerErrorResponseBody(responseDump []byte) []byte { |
| 61 | if _, body, ok := bytes.Cut(responseDump, []byte("\r\n\r\n")); ok { |
| 62 | return body |
| 63 | } |
| 64 | if _, body, ok := bytes.Cut(responseDump, []byte("\n\n")); ok { |
| 65 | return body |
| 66 | } |
| 67 | return responseDump |
| 68 | } |
| 69 | |
| 70 | func retryAfterFromHeaders(headers map[string]string) time.Duration { |
| 71 | if len(headers) == 0 { |
no outgoing calls
no test coverage detected