@@ -1465,29 +1465,30 @@ where
14651465 self . runtime . spawn_cancellable_background_task ( future) ;
14661466 } ,
14671467 LdkEvent :: BumpTransaction ( bte) => {
1468- match bte {
1468+ let ( channel_id , counterparty_node_id ) = match bte {
14691469 BumpTransactionEvent :: ChannelClose {
14701470 ref channel_id,
14711471 ref counterparty_node_id,
14721472 ..
1473- } => {
1474- // Skip bumping channel closes if our counterparty is trusted.
1475- if let Some ( anchor_channels_config) =
1476- self . config . anchor_channels_config . as_ref ( )
1477- {
1478- if anchor_channels_config
1479- . trusted_peers_no_reserve
1480- . contains ( counterparty_node_id)
1481- {
1482- log_debug ! ( self . logger,
1483- "Ignoring BumpTransactionEvent::ChannelClose for channel {} due to trusted counterparty {}" ,
1484- channel_id, counterparty_node_id
1485- ) ;
1486- return Ok ( ( ) ) ;
1487- }
1488- }
1489- } ,
1490- BumpTransactionEvent :: HTLCResolution { .. } => { } ,
1473+ } => ( channel_id, counterparty_node_id) ,
1474+ BumpTransactionEvent :: HTLCResolution {
1475+ ref channel_id,
1476+ ref counterparty_node_id,
1477+ ..
1478+ } => ( channel_id, counterparty_node_id) ,
1479+ } ;
1480+
1481+ if let Some ( anchor_channels_config) = self . config . anchor_channels_config . as_ref ( ) {
1482+ if anchor_channels_config
1483+ . trusted_peers_no_reserve
1484+ . contains ( counterparty_node_id)
1485+ {
1486+ log_debug ! ( self . logger,
1487+ "Ignoring BumpTransactionEvent for channel {} due to trusted counterparty {}" ,
1488+ channel_id, counterparty_node_id
1489+ ) ;
1490+ return Ok ( ( ) ) ;
1491+ }
14911492 }
14921493
14931494 self . bump_tx_event_handler . handle_event ( & bte) . await ;
0 commit comments