From: Greg Burri Date: Thu, 22 Sep 2022 12:07:49 +0000 (+0200) Subject: 'memory' is now in bytes. X-Git-Url: http://git.euphorik.ch/?p=valheim_web.git;a=commitdiff_plain;h=745387dbdf62a58db23a753f3a8ec8ac7e937a0e 'memory' is now in bytes. --- diff --git a/backend/src/valheim_controller.rs b/backend/src/valheim_controller.rs index aa0ff31..a7f10b5 100644 --- a/backend/src/valheim_controller.rs +++ b/backend/src/valheim_controller.rs @@ -8,7 +8,7 @@ use systemd::journal; #[derive(Clone, Debug)] pub struct ValheimExe { - memory: u64, // [kB]. + memory: u64, // [B]. load_average_5min: f64, // [%]. uptime: u64, // [s]. world_size: u64, // [B]. @@ -18,7 +18,7 @@ pub struct ValheimExe { impl ValheimExe { pub fn format_memory(&self) -> String { - format_byte_size(self.memory * 1024, 2) + format_byte_size(self.memory, 2) } pub fn format_load_average(&self) -> String {