From: Matt Corallo Date: Tue, 1 Mar 2022 03:46:52 +0000 (+0000) Subject: Make `as_directed_to` non-public X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=commitdiff_plain;h=057da7c423d4602a31303c0f72082859d3a3f655;p=rust-lightning Make `as_directed_to` non-public ...as the bindings generation does not currently have the ability to map a reference to a `NodeId` inside a tuple. --- diff --git a/lightning/src/routing/gossip.rs b/lightning/src/routing/gossip.rs index 3f9313c68..4ec68264d 100644 --- a/lightning/src/routing/gossip.rs +++ b/lightning/src/routing/gossip.rs @@ -791,7 +791,7 @@ pub struct ChannelInfo { impl ChannelInfo { /// Returns a [`DirectedChannelInfo`] for the channel directed to the given `target` from a /// returned `source`, or `None` if `target` is not one of the channel's counterparties. - pub fn as_directed_to(&self, target: &NodeId) -> Option<(DirectedChannelInfo, &NodeId)> { + pub(crate) fn as_directed_to(&self, target: &NodeId) -> Option<(DirectedChannelInfo, &NodeId)> { let (direction, source) = { if target == &self.node_one { (self.two_to_one.as_ref(), &self.node_two)