Skip to content

Commit

Permalink
fix: use generic instead of not generating purl (anchore#1119)
Browse files Browse the repository at this point in the history
  • Loading branch information
cpendery committed Jul 27, 2022
1 parent 16a85ed commit dbd2895
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions syft/pkg/url.go
Expand Up @@ -41,9 +41,7 @@ func URL(p Package, release *linux.Release) string {

switch {
case purlType == "":
// there is no purl type, don't attempt to craft a purl
// TODO: should this be a "generic" purl type instead?
return ""
purlType = packageurl.TypeGeneric
case p.Type == GoModulePkg:
re := regexp.MustCompile(`(/)[^/]*$`)
fields := re.Split(p.Name, -1)
Expand Down

0 comments on commit dbd2895

Please sign in to comment.