From f89b7d6fa9c4ce4e6a9fb14e5a39e088a3e73095 Mon Sep 17 00:00:00 2001 From: Valentine Wallace Date: Tue, 7 Mar 2023 17:13:57 -0500 Subject: [PATCH] Ensure payment_params present when checking is_retryable_now --- lightning/src/ln/outbound_payment.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lightning/src/ln/outbound_payment.rs b/lightning/src/ln/outbound_payment.rs index 291a17fda..6ede956b7 100644 --- a/lightning/src/ln/outbound_payment.rs +++ b/lightning/src/ln/outbound_payment.rs @@ -79,7 +79,9 @@ impl PendingOutboundPayment { } fn is_auto_retryable_now(&self) -> bool { match self { - PendingOutboundPayment::Retryable { retry_strategy: Some(strategy), attempts, .. } => { + PendingOutboundPayment::Retryable { + retry_strategy: Some(strategy), attempts, payment_params: Some(_), .. + } => { strategy.is_retryable_now(&attempts) }, _ => false, @@ -531,7 +533,7 @@ impl OutboundPayments { })); break } - } + } else { debug_assert!(false); } } } core::mem::drop(outbounds); -- 2.39.5