Skip to content

Commit

Permalink
fix: clear sbom-slice
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Kotzbauer <[email protected]>
  • Loading branch information
ckotzbauer committed Feb 19, 2022
1 parent a3751d3 commit 042d3e2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions internal/vuln/source/git_source.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ func (g *GitSource) Initialize() {
}

func (g *GitSource) LoadSboms() []Sbom {
g.sboms = []Sbom{}
ignoreDirs := []string{".git"}
sbomFileNames := []string{"sbom.json", "sbom.txt", "sbom.xml", "sbom.spdx"}
err := filepath.Walk(filepath.Join(g.workingTree, g.workPath), g.filterSboms(ignoreDirs, sbomFileNames))
Expand Down

0 comments on commit 042d3e2

Please sign in to comment.