diff --git a/graduated-rebalancer/Cargo.toml b/graduated-rebalancer/Cargo.toml index ab75ce0..b18a230 100644 --- a/graduated-rebalancer/Cargo.toml +++ b/graduated-rebalancer/Cargo.toml @@ -10,4 +10,4 @@ license = "MIT OR Apache-2.0" bitcoin-payment-instructions = { workspace = true } lightning = { workspace = true } lightning-invoice = { workspace = true } -tokio = { version = "1", default-features = false } +tokio = { version = "1", default-features = false, features = ["sync"] } diff --git a/graduated-rebalancer/src/lib.rs b/graduated-rebalancer/src/lib.rs index 3774eac..19e4261 100644 --- a/graduated-rebalancer/src/lib.rs +++ b/graduated-rebalancer/src/lib.rs @@ -341,7 +341,7 @@ where /// Perform on-chain to lightning rebalance by opening a channel or splicing into an existing one async fn do_onchain_rebalance(&self, params: TriggerParams) { - let _ = self.balance_mutex.lock().await; + let _lock = self.balance_mutex.lock().await; let (channel_outpoint, user_channel_id) = if self.ln_wallet.has_channel_with_lsp() { log_info!(self.logger, "Splicing into channel with LSP with on-chain funds");