@@ -409,7 +409,7 @@ impl OutboundPayments {
409
409
u32 , PaymentId , & Option < PaymentPreimage > , [ u8 ; 32 ] ) -> Result < ( ) , APIError >
410
410
{
411
411
let onion_session_privs = self . add_new_pending_payment ( payment_hash, * payment_secret, payment_id, route, Retry :: Attempts ( 0 ) , None , entropy_source, best_block_height) ?;
412
- self . send_payment_internal ( route, payment_hash, payment_secret, None , payment_id, None ,
412
+ self . pay_route_internal ( route, payment_hash, payment_secret, None , payment_id, None ,
413
413
onion_session_privs, node_signer, best_block_height, & send_payment_along_path)
414
414
. map_err ( |e| { self . remove_outbound_if_all_failed ( payment_id, & e) ; e } )
415
415
}
@@ -431,7 +431,7 @@ impl OutboundPayments {
431
431
let payment_hash = PaymentHash ( Sha256 :: hash ( & preimage. 0 ) . into_inner ( ) ) ;
432
432
let onion_session_privs = self . add_new_pending_payment ( payment_hash, None , payment_id, & route, Retry :: Attempts ( 0 ) , None , entropy_source, best_block_height) ?;
433
433
434
- match self . send_payment_internal ( route, payment_hash, & None , Some ( preimage) , payment_id, None , onion_session_privs, node_signer, best_block_height, & send_payment_along_path) {
434
+ match self . pay_route_internal ( route, payment_hash, & None , Some ( preimage) , payment_id, None , onion_session_privs, node_signer, best_block_height, & send_payment_along_path) {
435
435
Ok ( ( ) ) => Ok ( payment_hash) ,
436
436
Err ( e) => {
437
437
self . remove_outbound_if_all_failed ( payment_id, & e) ;
@@ -508,7 +508,7 @@ impl OutboundPayments {
508
508
509
509
let res = if let Some ( ( payment_hash, payment_secret, retry_strategy) ) = initial_send_info {
510
510
let onion_session_privs = self . add_new_pending_payment ( payment_hash, * payment_secret, payment_id, & route, retry_strategy, Some ( route_params. clone ( ) ) , entropy_source, best_block_height) ?;
511
- self . send_payment_internal ( & route, payment_hash, payment_secret, None , payment_id, None , onion_session_privs, node_signer, best_block_height, send_payment_along_path)
511
+ 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)
512
512
} else {
513
513
self . retry_payment_with_route ( & route, payment_id, entropy_source, node_signer, best_block_height, send_payment_along_path)
514
514
} ;
@@ -617,7 +617,7 @@ impl OutboundPayments {
617
617
} ) ) ,
618
618
}
619
619
} ;
620
- self . send_payment_internal ( route, payment_hash, & payment_secret, None , payment_id, Some ( total_msat) , onion_session_privs, node_signer, best_block_height, & send_payment_along_path)
620
+ self . pay_route_internal ( route, payment_hash, & payment_secret, None , payment_id, Some ( total_msat) , onion_session_privs, node_signer, best_block_height, & send_payment_along_path)
621
621
}
622
622
623
623
pub ( super ) fn send_probe < ES : Deref , NS : Deref , F > (
@@ -643,7 +643,7 @@ impl OutboundPayments {
643
643
let route = Route { paths : vec ! [ hops] , payment_params : None } ;
644
644
let onion_session_privs = self . add_new_pending_payment ( payment_hash, None , payment_id, & route, Retry :: Attempts ( 0 ) , None , entropy_source, best_block_height) ?;
645
645
646
- match self . send_payment_internal ( & route, payment_hash, & None , None , payment_id, None , onion_session_privs, node_signer, best_block_height, & send_payment_along_path) {
646
+ match self . pay_route_internal ( & route, payment_hash, & None , None , payment_id, None , onion_session_privs, node_signer, best_block_height, & send_payment_along_path) {
647
647
Ok ( ( ) ) => Ok ( ( payment_hash, payment_id) ) ,
648
648
Err ( e) => {
649
649
self . remove_outbound_if_all_failed ( payment_id, & e) ;
@@ -696,7 +696,7 @@ impl OutboundPayments {
696
696
}
697
697
}
698
698
699
- fn send_payment_internal < NS : Deref , F > (
699
+ fn pay_route_internal < NS : Deref , F > (
700
700
& self , route : & Route , payment_hash : PaymentHash , payment_secret : & Option < PaymentSecret > ,
701
701
keysend_preimage : Option < PaymentPreimage > , payment_id : PaymentId , recv_value_msat : Option < u64 > ,
702
702
onion_session_privs : Vec < [ u8 ; 32 ] > , node_signer : & NS , best_block_height : u32 ,
@@ -813,7 +813,7 @@ impl OutboundPayments {
813
813
F : Fn ( & Vec < RouteHop > , & Option < PaymentParameters > , & PaymentHash , & Option < PaymentSecret > , u64 ,
814
814
u32 , PaymentId , & Option < PaymentPreimage > , [ u8 ; 32 ] ) -> Result < ( ) , APIError >
815
815
{
816
- self . send_payment_internal ( route, payment_hash, payment_secret, keysend_preimage, payment_id,
816
+ self . pay_route_internal ( route, payment_hash, payment_secret, keysend_preimage, payment_id,
817
817
recv_value_msat, onion_session_privs, node_signer, best_block_height,
818
818
& send_payment_along_path)
819
819
. map_err ( |e| { self . remove_outbound_if_all_failed ( payment_id, & e) ; e } )
0 commit comments