Skip to content

Commit b0e61d9

Browse files
Expose blinded paths' advance_path_by_one methods.
Useful for LDK users that are using the onion messages module, like LNDK.
1 parent 0ac13e8 commit b0e61d9

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

lightning/src/blinded_path/message.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -249,11 +249,11 @@ pub(super) fn blinded_hops<T: secp256k1::Signing + secp256k1::Verification>(
249249
utils::construct_blinded_hops(secp_ctx, pks, tlvs, session_priv)
250250
}
251251

252-
// Advance the blinded onion message path by one hop, so make the second hop into the new
253-
// introduction node.
254-
//
255-
// Will only modify `path` when returning `Ok`.
256-
pub(crate) fn advance_path_by_one<NS: Deref, NL: Deref, T>(
252+
/// Advance the blinded onion message path by one hop, so make the second hop into the new
253+
/// introduction node.
254+
///
255+
/// Will only modify `path` when returning `Ok`.
256+
pub fn advance_path_by_one<NS: Deref, NL: Deref, T>(
257257
path: &mut BlindedMessagePath, node_signer: &NS, node_id_lookup: &NL, secp_ctx: &Secp256k1<T>
258258
) -> Result<(), ()>
259259
where

lightning/src/blinded_path/payment.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -341,11 +341,11 @@ pub(super) fn blinded_hops<T: secp256k1::Signing + secp256k1::Verification>(
341341
utils::construct_blinded_hops(secp_ctx, pks, tlvs, session_priv)
342342
}
343343

344-
// Advance the blinded onion payment path by one hop, so make the second hop into the new
345-
// introduction node.
346-
//
347-
// Will only modify `path` when returning `Ok`.
348-
pub(crate) fn advance_path_by_one<NS: Deref, NL: Deref, T>(
344+
/// Advance the blinded onion payment path by one hop, so make the second hop into the new
345+
/// introduction node.
346+
///
347+
/// Will only modify `path` when returning `Ok`.
348+
pub fn advance_path_by_one<NS: Deref, NL: Deref, T>(
349349
path: &mut BlindedPaymentPath, node_signer: &NS, node_id_lookup: &NL, secp_ctx: &Secp256k1<T>
350350
) -> Result<(), ()>
351351
where

0 commit comments

Comments
 (0)