Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions licenses/library.go
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ func Libraries(ctx context.Context, classifier Classifier, includeTests bool, ig
group, _ := errgroup.WithContext(ctx)
foundLicenseSlice := make([]struct {
candidate string
licenes []License
licenses []License
}, len(allCandidates))
counter := 0
for candidate := range allCandidates {
Expand All @@ -249,10 +249,10 @@ func Libraries(ctx context.Context, classifier Classifier, includeTests bool, ig

foundLicenseSlice[idx] = struct {
candidate string
licenes []License
licenses []License
}{
candidate: candidate,
licenes: licenses,
licenses: licenses,
}
return nil
})
Expand All @@ -264,11 +264,11 @@ func Libraries(ctx context.Context, classifier Classifier, includeTests bool, ig

foundLicenses := map[string][]License{}
for _, found := range foundLicenseSlice {
if len(found.licenes) == 0 {
if len(found.licenses) == 0 {
continue
}

foundLicenses[found.candidate] = found.licenes
foundLicenses[found.candidate] = found.licenses
}

pkgsByLicense := make(map[string][]pkgInfo)
Expand Down