From 88d48f49d0affcc572f3c96a84560ae1fac3c69e Mon Sep 17 00:00:00 2001 From: "mgsloan@gmail.com" Date: Wed, 20 Nov 2024 17:37:12 -0700 Subject: [PATCH] Log errors in more places in live_kit_client --- crates/live_kit_client/src/live_kit_client.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/crates/live_kit_client/src/live_kit_client.rs b/crates/live_kit_client/src/live_kit_client.rs index 580b99d4373cb..845922f90df20 100644 --- a/crates/live_kit_client/src/live_kit_client.rs +++ b/crates/live_kit_client/src/live_kit_client.rs @@ -254,7 +254,7 @@ pub fn capture_local_audio_track( let source = source.clone(); async move { while let Some(frame) = frame_rx.next().await { - source.capture_frame(&frame).await.ok(); + source.capture_frame(&frame).await.log_err(); } Ok(Some(())) } @@ -302,7 +302,7 @@ pub fn play_remote_audio_track( if stream_config.as_ref().map_or(true, |c| *c != frame_config) { buffer.resize(buffer_size as usize, 0); stream_config = Some(frame_config.clone()); - stream_config_tx.send(frame_config).ok(); + stream_config_tx.send(frame_config).log_err(); } if frame.data.len() == buffer.len() { @@ -327,7 +327,7 @@ pub fn play_remote_audio_track( .context("no audio output device available")?; let mut _output_stream = None; - while let Some(config) = stream_config_rx.recv().ok() { + while let Some(config) = stream_config_rx.recv().log_err() { _output_stream = Some(device.build_output_stream( &config, {