Skip to content

Commit d626653

Browse files
committed
Add additional docs for list_pending_payments
1 parent 93bf16b commit d626653

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lightning/src/ln/channelmanager.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1642,6 +1642,11 @@ impl<M: Deref, T: Deref, K: Deref, F: Deref, L: Deref> ChannelManager<M, T, K, F
16421642
}
16431643

16441644
/// Gets a list of payments in random order that are currently pending resolution.
1645+
///
1646+
/// This can be useful for figuring out whether or not a payment made needs to be retried.
1647+
/// In general, if it is not listed here, you should consider retrying it with a caveat: if a
1648+
/// payment is returned as [`RecentPaymentDetails::Fulfilled`], you may retry it, but should
1649+
/// not.
16451650
pub fn list_pending_payments(&self) -> Vec<RecentPaymentDetails> {
16461651
self.pending_outbound_payments.pending_outbound_payments.lock().unwrap().iter()
16471652
.filter_map(|(_, pending_outbound_payment)| match pending_outbound_payment {

0 commit comments

Comments
 (0)