From 1de999b87be98eedc07e703931fcb3a341416f91 Mon Sep 17 00:00:00 2001 From: emma31-dev Date: Sat, 17 Oct 2026 10:08:22 +0100 Subject: [PATCH] Skip unknown UTXOs when unlocking offline Warn and continue instead of unlocking outpoints that aren't known wallet UTXOs. --- src/handlers/offline.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/handlers/offline.rs b/src/handlers/offline.rs index 15cdd26b..c45c325d 100644 --- a/src/handlers/offline.rs +++ b/src/handlers/offline.rs @@ -884,6 +884,10 @@ impl AppCommand>> for UnlockUtxoCommand { fn execute(&self, ctx: &mut AppContext>) -> Result { let wallet = &mut ctx.state.wallet; for out_point in &self.utxos { + if wallet.get_utxo(*out_point).is_none() { + eprintln!("warning: {out_point} is not a known wallet UTXO; skipping"); + continue; + } wallet.unlock_outpoint(*out_point); } let locked = wallet