Skip to content

Commit

Permalink
refactor: delete PkgID
Browse files Browse the repository at this point in the history
Signed-off-by: knqyf263 <[email protected]>
  • Loading branch information
knqyf263 committed Jun 28, 2024
1 parent ff0ddfb commit 06443ac
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 5 deletions.
1 change: 0 additions & 1 deletion pkg/sbom/core/bom.go
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,6 @@ type Relationship struct {
type Vulnerability struct {
dtypes.Vulnerability
ID string
PkgID string
PkgName string
InstalledVersion string
FixedVersion string
Expand Down
1 change: 0 additions & 1 deletion pkg/sbom/io/encode.go
Original file line number Diff line number Diff line change
Expand Up @@ -377,7 +377,6 @@ func (*Encoder) vulnerability(vuln types.DetectedVulnerability) core.Vulnerabili
return core.Vulnerability{
Vulnerability: vuln.Vulnerability,
ID: vuln.VulnerabilityID,
PkgID: vuln.PkgID,
PkgName: vuln.PkgName,
InstalledVersion: vuln.InstalledVersion,
FixedVersion: vuln.FixedVersion,
Expand Down
3 changes: 0 additions & 3 deletions pkg/sbom/io/encode_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,6 @@ func TestEncoder_Encode(t *testing.T) {
uuid.MustParse("3ff14136-e09f-4df9-80ea-000000000004"): {
{
ID: "CVE-2021-22876",
PkgID: "[email protected]",
PkgName: "curl",
InstalledVersion: "7.50.3-1",
FixedVersion: "7.50.3-1+deb9u1",
Expand All @@ -391,7 +390,6 @@ func TestEncoder_Encode(t *testing.T) {
uuid.MustParse("3ff14136-e09f-4df9-80ea-000000000005"): {
{
ID: "CVE-2022-42003",
PkgID: "com.fasterxml.jackson.core:jackson-databind:2.13.4",
PkgName: "com.fasterxml.jackson.core:jackson-databind",
InstalledVersion: "2.13.4",
FixedVersion: "2.12.7.1, 2.13.4.2",
Expand All @@ -403,7 +401,6 @@ func TestEncoder_Encode(t *testing.T) {
uuid.MustParse("3ff14136-e09f-4df9-80ea-000000000006"): {
{
ID: "CVE-2022-42003",
PkgID: "com.fasterxml.jackson.core:jackson-databind:2.13.4",
PkgName: "com.fasterxml.jackson.core:jackson-databind",
InstalledVersion: "2.13.4",
FixedVersion: "2.12.7.1, 2.13.4.2",
Expand Down

0 comments on commit 06443ac

Please sign in to comment.