Closed ferozsalam closed 9 months ago
On the latest release (v1.6.2) of the Action, SARIF uploads fail when a container has zero vulnerabilities. The error is:
Failed formatting SARIF: Cannot read properties of undefined (reading 'filter')
The change in this PR ensures that the vulnerabilities variable is always defined, so that this error does not occur.
Tested this locally against images with and without vulnerabilities.
cc @sgordon46 – this fixes an edge case bug introduced in the latest release, would appreciate it if you could take a look!
Description
On the latest release (v1.6.2) of the Action, SARIF uploads fail when a container has zero vulnerabilities. The error is:
Failed formatting SARIF: Cannot read properties of undefined (reading 'filter')
The change in this PR ensures that the vulnerabilities variable is always defined, so that this error does not occur.
How Has This Been Tested?
Tested this locally against images with and without vulnerabilities.
Types of changes
Checklist