@@ -540,7 +540,7 @@ impl OutboundPayments {
540
540
} ) ) ?;
541
541
542
542
let res = if let Some ( ( payment_hash, payment_secret, retry_strategy) ) = initial_send_info {
543
- let onion_session_privs = self . add_new_pending_payment ( payment_hash, * payment_secret, payment_id, & route, Some ( retry_strategy) , Some ( route_params. clone ( ) ) , entropy_source, best_block_height) ?;
543
+ let onion_session_privs = self . add_new_pending_payment ( payment_hash, * payment_secret, payment_id, & route, Some ( retry_strategy) , Some ( route_params. payment_params . clone ( ) ) , entropy_source, best_block_height) ?;
544
544
self . pay_route_internal ( & route, payment_hash, payment_secret, None , payment_id, None , onion_session_privs, node_signer, best_block_height, send_payment_along_path)
545
545
} else {
546
546
self . retry_payment_with_route ( & route, payment_id, entropy_source, node_signer, best_block_height, send_payment_along_path)
@@ -690,7 +690,7 @@ impl OutboundPayments {
690
690
691
691
pub ( super ) fn add_new_pending_payment < ES : Deref > (
692
692
& self , payment_hash : PaymentHash , payment_secret : Option < PaymentSecret > , payment_id : PaymentId ,
693
- route : & Route , retry_strategy : Option < Retry > , route_params : Option < RouteParameters > ,
693
+ route : & Route , retry_strategy : Option < Retry > , payment_params : Option < PaymentParameters > ,
694
694
entropy_source : & ES , best_block_height : u32
695
695
) -> Result < Vec < [ u8 ; 32 ] > , PaymentSendFailure > where ES :: Target : EntropySource {
696
696
let mut onion_session_privs = Vec :: with_capacity ( route. paths . len ( ) ) ;
@@ -705,7 +705,7 @@ impl OutboundPayments {
705
705
let payment = entry. insert ( PendingOutboundPayment :: Retryable {
706
706
retry_strategy,
707
707
attempts : PaymentAttempts :: new ( ) ,
708
- payment_params : route_params . map ( |p| p . payment_params ) ,
708
+ payment_params,
709
709
session_privs : HashSet :: new ( ) ,
710
710
pending_amt_msat : 0 ,
711
711
pending_fee_msat : Some ( 0 ) ,
@@ -1248,7 +1248,7 @@ mod tests {
1248
1248
1249
1249
let err = if on_retry {
1250
1250
outbound_payments. add_new_pending_payment ( PaymentHash ( [ 0 ; 32 ] ) , None , PaymentId ( [ 0 ; 32 ] ) ,
1251
- & Route { paths : vec ! [ ] , payment_params : None } , Some ( Retry :: Attempts ( 1 ) ) , Some ( route_params. clone ( ) ) ,
1251
+ & Route { paths : vec ! [ ] , payment_params : None } , Some ( Retry :: Attempts ( 1 ) ) , Some ( route_params. payment_params . clone ( ) ) ,
1252
1252
& & keys_manager, 0 ) . unwrap ( ) ;
1253
1253
outbound_payments. pay_internal (
1254
1254
PaymentId ( [ 0 ; 32 ] ) , None , route_params, & & router, vec ! [ ] , InFlightHtlcs :: new ( ) ,
0 commit comments