diff --git a/core/pkg/resultshandling/printer/v2/sarifprinter.go b/core/pkg/resultshandling/printer/v2/sarifprinter.go index 6fe2c2e6..0bedb548 100644 --- a/core/pkg/resultshandling/printer/v2/sarifprinter.go +++ b/core/pkg/resultshandling/printer/v2/sarifprinter.go @@ -199,7 +199,7 @@ func (sp *SARIFPrinter) printConfigurationScan(ctx context.Context, opaSessionOb filepath := resourceSource.RelativePath // Github Code Scanning considers results not associated to a file path meaningless and invalid when uploading - if filepath == "" || basePath == "" { + if filepath == "" && basePath == "" { continue }