don't show player zero in reports

This commit is contained in:
Jonathan Lamothe 2019-12-28 20:59:04 -05:00
parent 89fe646d0e
commit 2840298467
2 changed files with 6 additions and 2 deletions

View File

@ -1,5 +1,8 @@
# Changelog for mtlstats
## current
- Don't show player number zero in reports
## 0.9.0
- Bugfix: Display lifetime stats in report, not YTD
- Force expected capitalization on player/goalie names

View File

@ -189,8 +189,9 @@ filteredPlayerReport
-> [(Player, PlayerStats)]
-> [String]
filteredPlayerReport width label criteria showTotals ps = let
tStats = foldl addPlayerStats newPlayerStats $ map snd ps
fps = filter criteria ps
tStats = foldl addPlayerStats newPlayerStats $ map snd ps
criteria' = (&&) <$> criteria <*> \(p, _) -> p^.pNumber /= 0
fps = filter criteria' ps
rHeader =
[ centre width (label ++ " STATISTICS")