Keep it tight
This commit is contained in:
parent
09320bb71c
commit
1c25d2550b
@ -52,9 +52,8 @@ export default function Component({ service }) {
|
||||
}
|
||||
|
||||
function toPercent(value, total) {
|
||||
const percentage = (value / total) * 100;
|
||||
return t("common.percent", {
|
||||
value: !Number.isNaN(percentage) ? percentage : 0,
|
||||
value: !Number.isNaN(value / total) ? 100 * (value / total) : 0,
|
||||
maximumFractionDigits: 2,
|
||||
});
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user