From 9605a476168abca358da079f9ffa004a61e8112b Mon Sep 17 00:00:00 2001 From: Jason Hall Date: Thu, 20 Jan 2022 13:00:28 -0500 Subject: [PATCH] Remove unnecessary nil check which was confusing linter --- cmd/cosign/cli/options/registry.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/cosign/cli/options/registry.go b/cmd/cosign/cli/options/registry.go index a1910533e73b..3bb6dd29fe1d 100644 --- a/cmd/cosign/cli/options/registry.go +++ b/cmd/cosign/cli/options/registry.go @@ -83,7 +83,7 @@ func (o *RegistryOptions) GetRegistryClientOpts(ctx context.Context) []remote.Op opts = append(opts, remote.WithAuthFromKeychain(authn.DefaultKeychain)) } - if o != nil && o.AllowInsecure { + if o.AllowInsecure { opts = append(opts, remote.WithTransport(&http.Transport{TLSClientConfig: &tls.Config{InsecureSkipVerify: true}})) // #nosec G402 } return opts