diff --git a/lib/core/src/swapper/boltz/status_stream.rs b/lib/core/src/swapper/boltz/status_stream.rs index 0cf684a..d8750c5 100644 --- a/lib/core/src/swapper/boltz/status_stream.rs +++ b/lib/core/src/swapper/boltz/status_stream.rs @@ -46,6 +46,18 @@ impl SwapperStatusStream for BoltzSwapper

{ tokio::spawn(async move { loop { debug!("Start of ws stream loop"); + match shutdown.has_changed() { + Ok(true) => { + info!("Received shutdown signal, exiting Status Stream loop"); + return; + } + Ok(false) => {} + Err(_) => { + warn!("Shutdown channel was closed, exiting Status Stream loop"); + return; + } + } + let mut request_stream = self.request_notifier.subscribe(); let client = match swapper.get_boltz_client().await { Ok(client) => client,