From 9802b6e1ffd7eb3bce02278202a2e9ce4238cee8 Mon Sep 17 00:00:00 2001 From: Thomas Poignant Date: Wed, 14 Aug 2024 22:03:37 +0200 Subject: [PATCH] fix: ci check after golangci-lint update (#2221) Signed-off-by: Thomas Poignant Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com> --- config.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config.go b/config.go index fbb1146cdf1..c917b18aefe 100644 --- a/config.go +++ b/config.go @@ -103,7 +103,7 @@ type Config struct { // GetRetrievers returns a retriever.Retriever configure with the retriever available in the config. func (c *Config) GetRetrievers() ([]retriever.Retriever, error) { - if c.Retriever == nil && (c.Retrievers == nil || len(c.Retrievers) == 0) { + if c.Retriever == nil && len(c.Retrievers) == 0 { return nil, errors.New("no retriever in the configuration, impossible to get the flags") } @@ -113,7 +113,7 @@ func (c *Config) GetRetrievers() ([]retriever.Retriever, error) { if c.Retriever != nil { retrievers = append(retrievers, c.Retriever) } - if c.Retrievers != nil && len(c.Retrievers) > 0 { + if len(c.Retrievers) > 0 { retrievers = append(retrievers, c.Retrievers...) } return retrievers, nil