[chore](trx-rs): address clippy warnings

Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
This commit is contained in:
2026-02-09 21:26:53 +01:00
parent cf11c16096
commit 5f3ea48ef7
3 changed files with 10 additions and 15 deletions
@@ -483,14 +483,9 @@ async fn wait_for_view(mut rx: watch::Receiver<RigState>) -> Result<RigSnapshot,
// Wait up to 5 seconds for a valid snapshot; fall back to a placeholder
// so the SSE stream starts immediately and the browser isn't left hanging.
let deadline = time::Instant::now() + Duration::from_secs(5);
loop {
match time::timeout_at(deadline, rx.changed()).await {
Ok(Ok(())) => {
if let Some(view) = rx.borrow().snapshot() {
return Ok(view);
}
}
_ => break,
while let Ok(Ok(())) = time::timeout_at(deadline, rx.changed()).await {
if let Some(view) = rx.borrow().snapshot() {
return Ok(view);
}
}