mirror of
https://github.com/aquasecurity/trivy.git
synced 2025-12-05 20:40:16 -08:00
fix(java): avoid panic if deps from pom in it dir are not found (#7245)
This commit is contained in:
@@ -32,7 +32,7 @@ func (a pomAnalyzer) Analyze(_ context.Context, input analyzer.AnalysisInput) (*
|
||||
}
|
||||
|
||||
// Mark integration test pom files for `maven-invoker-plugin` as Dev to skip them by default.
|
||||
if isIntegrationTestDir(filePath) {
|
||||
if isIntegrationTestDir(filePath) && res != nil {
|
||||
for i := range res.Applications {
|
||||
for j := range res.Applications[i].Packages {
|
||||
res.Applications[i].Packages[j].Dev = true
|
||||
|
||||
Reference in New Issue
Block a user