Fix counts
This commit is contained in:
parent
d7f6126eb7
commit
80e0b87bd1
@ -496,22 +496,20 @@ func GetPackagesCount() domain.PackagesCount {
|
|||||||
Queued: 0,
|
Queued: 0,
|
||||||
Building: 0,
|
Building: 0,
|
||||||
}
|
}
|
||||||
currentPackages.ForEach(func(k string, v domain.SourcePackage) bool {
|
currentPackages.ForEach(func(k string, pkg domain.SourcePackage) bool {
|
||||||
v.Packages.ForEach(func(k string, pkg domain.PackageInfo) bool {
|
switch pkg.Status {
|
||||||
switch pkg.Status {
|
case domain.Stale:
|
||||||
case domain.Stale:
|
count.Stale++
|
||||||
count.Stale++
|
case domain.Missing:
|
||||||
case domain.Missing:
|
count.Missing++
|
||||||
count.Missing++
|
case domain.Built:
|
||||||
case domain.Built:
|
count.Current++
|
||||||
count.Current++
|
case domain.Current:
|
||||||
case domain.Current:
|
count.Current++
|
||||||
count.Current++
|
case domain.Error:
|
||||||
case domain.Error:
|
count.Error++
|
||||||
count.Error++
|
}
|
||||||
}
|
|
||||||
return false
|
|
||||||
})
|
|
||||||
return true
|
return true
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user