From deb99b5e6046bdc3bd18ed1136dd9e74cc17c183 Mon Sep 17 00:00:00 2001 From: Emmanuel Gautier Date: Sat, 17 Aug 2024 13:07:43 +0200 Subject: [PATCH] chore: omit nil check --- generator/generator.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/generator/generator.go b/generator/generator.go index f917467..2723fa0 100644 --- a/generator/generator.go +++ b/generator/generator.go @@ -56,7 +56,7 @@ func (g *Generator) createRule(verb string, path string, o *openapi3.Operation) if o.Security != nil && len(*o.Security) > 0 { appendAuthenticator(o.Security) - } else if g.doc.Security != nil && len(g.doc.Security) > 0 { + } else if len(g.doc.Security) > 0 { appendAuthenticator(&g.doc.Security) } else { ar, arerror := g.authenticators[string(authenticator.AuthenticatorTypeNoop)].CreateAuthenticator(nil)