From 63cf6ee96e2dc4e88b0782222d1c320d8a3943b3 Mon Sep 17 00:00:00 2001 From: Boy132 Date: Tue, 28 Jun 2022 00:30:00 +0200 Subject: [PATCH] fix: round cpu usage in chart (#4182) fixes #4168 --- resources/scripts/components/server/console/StatGraphs.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/scripts/components/server/console/StatGraphs.tsx b/resources/scripts/components/server/console/StatGraphs.tsx index 4c19bd1d5..a0049fef1 100644 --- a/resources/scripts/components/server/console/StatGraphs.tsx +++ b/resources/scripts/components/server/console/StatGraphs.tsx @@ -57,7 +57,7 @@ export default () => { return; } - cpu.push(values.cpu_absolute); + cpu.push(values.cpu_absolute.toFixed(2)); memory.push(Math.floor(values.memory_bytes / 1024 / 1024)); network.push([ previous.current.tx < 0 ? 0 : Math.max(0, values.network.tx_bytes - previous.current.tx),