mirror of
https://github.com/lukaszraczylo/gohoarder.git
synced 2026-11-26 06:37:07 +00:00
fix(packages): list only cache artifacts in the package rows
The rows layout listed Go .mod and .info files. They are never scanned, so they showed as pending and made the page total larger than /api/stats. The group query now applies the same artifact filter as GetStats.
This commit is contained in:
@@ -38,7 +38,7 @@ type groupAgg struct {
|
||||
func PageGroups(all []*Package, opts GroupListOptions) *GroupPage {
|
||||
groups := map[string]*groupAgg{}
|
||||
for _, p := range all {
|
||||
if IsMetadataVersion(p.Version) || (opts.Registry != "" && p.Registry != opts.Registry) || !MatchesQuery(p, opts.Query) {
|
||||
if IsMetadataEntry(p.Registry, p.Name, p.Version) || (opts.Registry != "" && p.Registry != opts.Registry) || !MatchesQuery(p, opts.Query) {
|
||||
continue
|
||||
}
|
||||
name := CleanName(p.Name)
|
||||
|
||||
Reference in New Issue
Block a user