From e57c880bd1a14a83ae4c4f16b2fc979da931b0ae Mon Sep 17 00:00:00 2001 From: user1823 <92206575+user1823@users.noreply.github.com> Date: Sun, 6 Apr 2025 15:39:03 +0530 Subject: [PATCH] Format eases.rs --- rslib/src/stats/graphs/eases.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rslib/src/stats/graphs/eases.rs b/rslib/src/stats/graphs/eases.rs index bb7ae2aa1..9b8e703e6 100644 --- a/rslib/src/stats/graphs/eases.rs +++ b/rslib/src/stats/graphs/eases.rs @@ -28,7 +28,7 @@ impl GraphsContext { ease_values.push(card.ease_factor as f32); } } - + eases.average = median(&mut ease_values) / 10.0; difficulty.average = median(&mut difficulty_values) * 100.0; @@ -37,7 +37,7 @@ impl GraphsContext { } /// Helper function to calculate the median of a vector -fn median(data: &mut Vec) -> f32 { +fn median(data: &mut [f32]) -> f32 { if data.is_empty() { return 0.0; }