fix #265: resolve all remaining clippy warnings (cast, too_many_lines, doc nits)

This commit is contained in:
damocles 2026-05-22 19:02:11 +02:00
commit 484cea62c7
12 changed files with 95 additions and 86 deletions

View file

@ -335,7 +335,9 @@ async fn api_stats(
// Pass the window span to the reminder-stats RPC so the broker
// filters its counts to the same time range as the chart data.
let window_secs = window.span_secs();
snapshot.reminder_stats = fetch_reminder_stats(&state.socket, state.flavor(), window_secs as u64).await;
#[allow(clippy::cast_sign_loss)] // window span is always a positive duration
let window_secs_u = window_secs.max(0) as u64;
snapshot.reminder_stats = fetch_reminder_stats(&state.socket, state.flavor(), window_secs_u).await;
axum::Json(snapshot)
}