Skip to content

Commit df2f25a

Browse files
committed
pkg/plugins: rename max/min as it collides with go1.21 builtin
Signed-off-by: Sebastiaan van Stijn <[email protected]>
1 parent 6c036f2 commit df2f25a

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

pkg/plugins/client.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -239,13 +239,13 @@ func (c *Client) callWithRetry(serviceMethod string, data io.Reader, retry bool,
239239
}
240240

241241
func backoff(retries int) time.Duration {
242-
b, max := 1, defaultTimeOut
243-
for b < max && retries > 0 {
242+
b, maxTimeout := 1, defaultTimeOut
243+
for b < maxTimeout && retries > 0 {
244244
b *= 2
245245
retries--
246246
}
247-
if b > max {
248-
b = max
247+
if b > maxTimeout {
248+
b = maxTimeout
249249
}
250250
return time.Duration(b) * time.Second
251251
}

0 commit comments

Comments
 (0)