From 2267800c51c799f3106c54284653e4ea6c30c725 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?m=C3=BCde?= Date: Fri, 15 May 2026 00:27:47 +0200 Subject: [PATCH] hive-m1nd: if-let-else instead of match --- hive-ag3nt/src/bin/hive-m1nd.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/hive-ag3nt/src/bin/hive-m1nd.rs b/hive-ag3nt/src/bin/hive-m1nd.rs index 498178f..a2989fc 100644 --- a/hive-ag3nt/src/bin/hive-m1nd.rs +++ b/hive-ag3nt/src/bin/hive-m1nd.rs @@ -95,9 +95,10 @@ async fn serve(socket: &Path, interval: Duration) -> Result<()> { match recv { Ok(ManagerResponse::Message { from, body }) => { if from == SYSTEM_SENDER { - match serde_json::from_str::(&body) { - Ok(event) => tracing::info!(?event, "helper event"), - Err(_) => tracing::info!(%from, %body, "system message"), + if let Ok(event) = serde_json::from_str::(&body) { + tracing::info!(?event, "helper event"); + } else { + tracing::info!(%from, %body, "system message"); } } else { tracing::info!(%from, %body, "manager inbox");