Skip to content

Commit ef8532f

Browse files
johanneslarssonashutosh-narkar
authored andcommitted
auth: requestToken close response body
Signed-off-by: Johannes Larsson <[email protected]>
1 parent 8260697 commit ef8532f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

plugins/rest/auth.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -541,6 +541,7 @@ func (ap *oauth2ClientCredentialsAuthPlugin) requestToken(ctx context.Context) (
541541
if err != nil {
542542
return nil, err
543543
}
544+
defer response.Body.Close()
544545

545546
bodyRaw, err := io.ReadAll(response.Body)
546547
if err != nil {

0 commit comments

Comments
 (0)