@@ -1385,23 +1385,21 @@ impl<Signer: Sign> ChannelMonitor<Signer> {
1385
1385
claimable_amount_satoshis: htlc. amount_msat / 1000 ,
1386
1386
claimable_height: htlc. cltv_expiry,
1387
1387
} ) ;
1388
- } else {
1389
- if us. payment_preimages. get( & htlc. payment_hash) . is_some( ) {
1390
- if let Some ( conf_thresh) = us. onchain_events_awaiting_threshold_conf. iter( ) . find_map( |event| {
1391
- if let OnchainEvent :: HTLCSpendConfirmation { input_idx, .. } = event. event {
1392
- if input_idx == htlc_input_idx { Some ( event. confirmation_threshold( ) ) } else { None }
1393
- } else { None }
1394
- } ) {
1395
- res. push( ClaimableBalance :: ClaimableAwaitingConfirmations {
1396
- claimable_amount_satoshis: htlc. amount_msat / 1000 ,
1397
- confirmation_height: conf_thresh,
1398
- } ) ;
1399
- } else {
1400
- res. push( ClaimableBalance :: ContentiousClaimable {
1401
- claimable_amount_satoshis: htlc. amount_msat / 1000 ,
1402
- timeout_height: htlc. cltv_expiry,
1403
- } ) ;
1404
- }
1388
+ } else if us. payment_preimages. get( & htlc. payment_hash) . is_some( ) {
1389
+ if let Some ( conf_thresh) = us. onchain_events_awaiting_threshold_conf. iter( ) . find_map( |event| {
1390
+ if let OnchainEvent :: HTLCSpendConfirmation { input_idx, .. } = event. event {
1391
+ if input_idx == htlc_input_idx { Some ( event. confirmation_threshold( ) ) } else { None }
1392
+ } else { None }
1393
+ } ) {
1394
+ res. push( ClaimableBalance :: ClaimableAwaitingConfirmations {
1395
+ claimable_amount_satoshis: htlc. amount_msat / 1000 ,
1396
+ confirmation_height: conf_thresh,
1397
+ } ) ;
1398
+ } else {
1399
+ res. push( ClaimableBalance :: ContentiousClaimable {
1400
+ claimable_amount_satoshis: htlc. amount_msat / 1000 ,
1401
+ timeout_height: htlc. cltv_expiry,
1402
+ } ) ;
1405
1403
}
1406
1404
}
1407
1405
}
0 commit comments