From 8bd30a970eebb7fed0406d5e5e03ad8d2550de2e Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 23 Mar 2026 14:12:32 +0000 Subject: [PATCH] style: run cargo fmt https://claude.ai/code/session_01Mdiz3XwyZcjqMkqicaynGs --- src/agent/agent_loop.rs | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/agent/agent_loop.rs b/src/agent/agent_loop.rs index 310f9378..70546c39 100644 --- a/src/agent/agent_loop.rs +++ b/src/agent/agent_loop.rs @@ -1149,9 +1149,10 @@ impl Agent { .await; let mut sess = session.lock().await; if let Some(thread) = sess.threads.get(&target_thread_id) { - let authorized = thread.source_channel.as_ref().is_none_or(|src| { - src == &message.channel || message.channel == "web" - }); + let authorized = thread + .source_channel + .as_ref() + .is_none_or(|src| src == &message.channel || message.channel == "web"); if !authorized { tracing::warn!( %target_thread_id, @@ -1160,7 +1161,9 @@ impl Agent { "Blocked cross-channel approval attempt" ); drop(sess); - return Ok(Some("Error: approval not authorized for this channel".into())); + return Ok(Some( + "Error: approval not authorized for this channel".into(), + )); } sess.active_thread = Some(target_thread_id); sess.last_active_at = chrono::Utc::now();