From a0cf7a08f44db843ca71be45e088017f9aac4db4 Mon Sep 17 00:00:00 2001 From: Rajat Bajaj Date: Mon, 11 Nov 2024 14:53:26 +0530 Subject: [PATCH] Updated var name to remove linting issue --- internal/client/client.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/internal/client/client.go b/internal/client/client.go index e0d73ef2..2bef50a3 100644 --- a/internal/client/client.go +++ b/internal/client/client.go @@ -161,9 +161,9 @@ func backoffDelay() rehttp.DelayFn { return func(attempt rehttp.Attempt) time.Duration { wait := baseDelay * math.Pow(2, float64(attempt.Index)) - min := wait + 1 - max := wait + baseDelay - wait = PRNG.Float64()*(max-min) + min + minValue := wait + 1 + maxValue := wait + baseDelay + wait = PRNG.Float64()*(maxValue-minValue) + minValue wait = math.Min(wait, maxDelay) wait = math.Max(wait, minDelay)