lint: gocritic/httpNoBody (#3493)

* lint: gocritic/httpNoBody
This commit is contained in:
mmetc 2025-03-07 14:35:25 +01:00 committed by GitHub
parent a203d8ebbf
commit 12a3c70860
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 34 additions and 36 deletions

View file

@ -160,7 +160,7 @@ func (p *Papi) GetPermissions(ctx context.Context) (PapiPermCheckSuccess, error)
httpClient := p.apiClient.GetClient()
papiCheckUrl := fmt.Sprintf("%s%s%s", p.URL, types.PAPIVersion, types.PAPIPermissionsUrl)
req, err := http.NewRequestWithContext(ctx, http.MethodGet, papiCheckUrl, nil)
req, err := http.NewRequestWithContext(ctx, http.MethodGet, papiCheckUrl, http.NoBody)
if err != nil {
return PapiPermCheckSuccess{}, fmt.Errorf("failed to create request: %w", err)
}