Skip to content

Commit 4dba7a3

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 e741a9a commit 4dba7a3

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
@@ -258,11 +258,11 @@ pub(super) fn blinded_hops<T: secp256k1::Signing + secp256k1::Verification>(
258258
utils::construct_blinded_hops(secp_ctx, pks, tlvs, session_priv)
259259
}
260260

261-
// Advance the blinded onion message path by one hop, so make the second hop into the new
262-
// introduction node.
263-
//
264-
// Will only modify `path` when returning `Ok`.
265-
pub(crate) fn advance_path_by_one<NS: Deref, NL: Deref, T>(
261+
/// Advance the blinded onion message path by one hop, so make the second hop into the new
262+
/// introduction node.
263+
///
264+
/// Will only modify `path` when returning `Ok`.
265+
pub fn advance_path_by_one<NS: Deref, NL: Deref, T>(
266266
path: &mut BlindedMessagePath, node_signer: &NS, node_id_lookup: &NL, secp_ctx: &Secp256k1<T>
267267
) -> Result<(), ()>
268268
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)