Skip to content

Commit 381ff40

Browse files
Update lightning/src/events/bump_transaction.rs
Co-authored-by: Matt Corallo <[email protected]>
1 parent 48930e3 commit 381ff40

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

lightning/src/events/bump_transaction.rs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -827,12 +827,10 @@ where
827827
.map(|utxo| utxo.satisfaction_weight)
828828
.sum::<u64>();
829829
#[cfg(debug_assertions)]
830-
let total_input_amount = must_spend_amount
831-
+ coin_selection
832-
.confirmed_utxos
833-
.iter()
834-
.map(|utxo| utxo.output.value.to_sat())
835-
.sum::<u64>();
830+
let input_value: u64 =
831+
coin_selection.confirmed_utxos.iter().map(|utxo| utxo.output.value.to_sat()).sum();
832+
#[cfg(debug_assertions)]
833+
let total_input_amount = must_spend_amount + input_value;
836834

837835
self.process_coin_selection(&mut htlc_tx, &coin_selection);
838836

0 commit comments

Comments
 (0)