Skip to content

Commit

Permalink
t
Browse files Browse the repository at this point in the history
  • Loading branch information
pna-nca committed Jul 31, 2024
1 parent 3b2fa67 commit 7e207d1
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions dojo/tools/trivy_operator/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,13 @@ def get_findings(self, scan_file, test):
if data is None:
return []

findings = []
if isinstance(data, dict):
self.handle_resource(data, test)
findings = self.handle_resource(data, test)
else:
for resource in data:
self.handle_resource(resource, test)
findings += self.handle_resource(resource, test)
return findings

def handle_resource(self, data, test):
metadata = data.get("metadata", None)
Expand Down

0 comments on commit 7e207d1

Please sign in to comment.