Thu, 15 Oct 2020 11:42:43 +0200
fixes progress percentages always floored resulting in 1% open even if there are no open issues
src/main/java/de/uapcore/lightpit/entities/IssueSummary.java | file | annotate | diff | comparison | revisions |
--- a/src/main/java/de/uapcore/lightpit/entities/IssueSummary.java Fri Oct 09 19:14:40 2020 +0200 +++ b/src/main/java/de/uapcore/lightpit/entities/IssueSummary.java Thu Oct 15 11:42:43 2020 +0200 @@ -39,12 +39,12 @@ public int getActivePercent() { int total = getTotal(); - return total > 0 ? 100*active/total : 0; + return total > 0 ? Math.round(100.f*active/total) : 0; } public int getDonePercent() { int total = getTotal(); - return total > 0 ? 100*done/total : 100; + return total > 0 ? Math.round(100.f*done/total) : 100; } /**