From 80018f5975f1133015bcc7cd74b6fd8008365e29 Mon Sep 17 00:00:00 2001 From: zirain Date: Sat, 9 Mar 2024 03:54:18 +0800 Subject: [PATCH] fix existing secret check (#2838) fix existing secret Signed-off-by: zirain --- internal/cmd/certgen.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/cmd/certgen.go b/internal/cmd/certgen.go index b83f6c71b21..afa626f8d9a 100644 --- a/internal/cmd/certgen.go +++ b/internal/cmd/certgen.go @@ -74,7 +74,7 @@ func outputCerts(ctx context.Context, cli client.Client, cfg *config.Server, cer log := cfg.Logger if err != nil { - if !errors.Is(err, kubernetes.ErrSecretExists) { + if errors.Is(err, kubernetes.ErrSecretExists) { log.Info(err.Error()) } else { return fmt.Errorf("failed to create or update secrets: %w", err)