From 4b1e1c814197030654aaa49bce3e9430d517e60f Mon Sep 17 00:00:00 2001 From: DmitriyLewen Date: Tue, 16 Jul 2024 13:44:40 +0600 Subject: [PATCH] refactor(misconfigs): use number of Misconfigurations to check --- pkg/report/table/misconfig.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/report/table/misconfig.go b/pkg/report/table/misconfig.go index 25f9a27688f5..112d783d0875 100644 --- a/pkg/report/table/misconfig.go +++ b/pkg/report/table/misconfig.go @@ -52,7 +52,7 @@ func NewMisconfigRenderer(result types.Result, severities []dbTypes.Severity, tr func (r *misconfigRenderer) Render() string { // Trivy doesn't currently support showing suppressed misconfigs // So just skip this result - if r.result.MisconfSummary.Failures == 0 { + if len(r.result.Misconfigurations) == 0 { return "" } target := fmt.Sprintf("%s (%s)", r.result.Target, r.result.Type)