From ebf7c8f076d841cb0914ccb5fbb46e82197166d4 Mon Sep 17 00:00:00 2001 From: Laurence Date: Fri, 25 Oct 2024 14:52:35 +0100 Subject: [PATCH] enhance: Remove if log check in one instance that was not needed as the logged items are not resource intensive --- pkg/apiclient/client_http.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/pkg/apiclient/client_http.go b/pkg/apiclient/client_http.go index 0240618f535..eeca929ea6e 100644 --- a/pkg/apiclient/client_http.go +++ b/pkg/apiclient/client_http.go @@ -61,9 +61,7 @@ func (c *ApiClient) Do(ctx context.Context, req *http.Request, v interface{}) (* req.Header.Add("User-Agent", c.UserAgent) } - if log.GetLevel() >= log.DebugLevel { - log.Debugf("[URL] %s %s", req.Method, req.URL) - } + log.Debugf("[URL] %s %s", req.Method, req.URL) resp, err := c.client.Do(req) if resp != nil && resp.Body != nil {