Skip to content

Commit d831270

Browse files
fixup! make persistent BOLT12 invoice through PendingOutboundPayment
Signed-off-by: Vincenzo Palazzo <[email protected]>
1 parent fcc1f09 commit d831270

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lightning/src/ln/outbound_payment.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -805,7 +805,7 @@ impl OutboundPayments {
805805
IH: Fn() -> InFlightHtlcs,
806806
SP: Fn(SendAlongPathArgs) -> Result<(), APIError>,
807807
{
808-
self.send_payment_internal(payment_id, payment_hash, recipient_onion, None, retry_strategy,
808+
self.send_payment_for_non_bolt12_invoice(payment_id, payment_hash, recipient_onion, None, retry_strategy,
809809
route_params, router, first_hops, &compute_inflight_htlcs, entropy_source, node_signer,
810810
best_block_height, logger, pending_events, &send_payment_along_path)
811811
}
@@ -828,7 +828,7 @@ impl OutboundPayments {
828828
let preimage = payment_preimage
829829
.unwrap_or_else(|| PaymentPreimage(entropy_source.get_secure_random_bytes()));
830830
let payment_hash = PaymentHash(Sha256::hash(&preimage.0).to_byte_array());
831-
self.send_payment_internal(payment_id, payment_hash, recipient_onion, Some(preimage),
831+
self.send_payment_for_non_bolt12_invoice(payment_id, payment_hash, recipient_onion, Some(preimage),
832832
retry_strategy, route_params, router, first_hops, inflight_htlcs, entropy_source,
833833
node_signer, best_block_height, logger, pending_events, send_payment_along_path)
834834
.map(|()| payment_hash)
@@ -1247,7 +1247,7 @@ impl OutboundPayments {
12471247
///
12481248
/// [`Event::PaymentPathFailed`]: crate::events::Event::PaymentPathFailed
12491249
/// [`Event::PaymentFailed`]: crate::events::Event::PaymentFailed
1250-
fn send_payment_internal<R: Deref, NS: Deref, ES: Deref, IH, SP, L: Deref>(
1250+
fn send_payment_for_non_bolt12_invoice<R: Deref, NS: Deref, ES: Deref, IH, SP, L: Deref>(
12511251
&self, payment_id: PaymentId, payment_hash: PaymentHash, recipient_onion: RecipientOnionFields,
12521252
keysend_preimage: Option<PaymentPreimage>, retry_strategy: Retry, mut route_params: RouteParameters,
12531253
router: &R, first_hops: Vec<ChannelDetails>, inflight_htlcs: IH, entropy_source: &ES,

0 commit comments

Comments
 (0)