From 1c455df18adaf8cce902f1fe84c24e5981425412 Mon Sep 17 00:00:00 2001 From: elsapet Date: Mon, 28 Nov 2022 14:35:07 +0200 Subject: [PATCH] WIP --- pkg/commands/artifact/run.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkg/commands/artifact/run.go b/pkg/commands/artifact/run.go index 5821f351d..4dabf7def 100644 --- a/pkg/commands/artifact/run.go +++ b/pkg/commands/artifact/run.go @@ -135,10 +135,8 @@ func Run(ctx context.Context, opts flag.Options, targetKind TargetKind) (err err return xerrors.Errorf("report error: %w", err) } - if reportPassed { - os.Exit(0) - } else { - os.Exit(1) + if !reportPassed { + defer os.Exit(1) } return nil