diff --git a/internal/discovery/client/client.go b/internal/discovery/client/client.go index 530e410..767308f 100644 --- a/internal/discovery/client/client.go +++ b/internal/discovery/client/client.go @@ -153,5 +153,5 @@ func GetRetryAfter(resp *http.Response) (time.Duration, bool) { if err != nil { return 0, false } - return time.Second * time.Duration(after + 1), true + return time.Second * time.Duration(after+1), true } diff --git a/internal/discovery/client/client_test.go b/internal/discovery/client/client_test.go index 83244e6..9a62888 100644 --- a/internal/discovery/client/client_test.go +++ b/internal/discovery/client/client_test.go @@ -189,7 +189,7 @@ func TestGetRetryAfter(t *testing.T) { &http.Response{Header: map[string][]string{ "Retry-After": []string{"3600"}, }}, - time.Second * 3600, true, + time.Second * 3601, true, }, "malformed header": { &http.Response{Header: map[string][]string{ "Retry-After": []string{"malformed"},