Skip to content

Commit 4d993c0

Browse files
authored
Merge pull request #2870 from benthecarman/pub-source-target
Make DirectedChannelInfo `source` and `target` public
2 parents 3751398 + a931dec commit 4d993c0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lightning/src/routing/gossip.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1032,13 +1032,13 @@ impl<'a> DirectedChannelInfo<'a> {
10321032
///
10331033
/// Refers to the `node_id` forwarding the payment to the next hop.
10341034
#[inline]
1035-
pub(super) fn source(&self) -> &'a NodeId { if self.from_node_one { &self.channel.node_one } else { &self.channel.node_two } }
1035+
pub fn source(&self) -> &'a NodeId { if self.from_node_one { &self.channel.node_one } else { &self.channel.node_two } }
10361036

10371037
/// Returns the `node_id` of the target hop.
10381038
///
10391039
/// Refers to the `node_id` receiving the payment from the previous hop.
10401040
#[inline]
1041-
pub(super) fn target(&self) -> &'a NodeId { if self.from_node_one { &self.channel.node_two } else { &self.channel.node_one } }
1041+
pub fn target(&self) -> &'a NodeId { if self.from_node_one { &self.channel.node_two } else { &self.channel.node_one } }
10421042
}
10431043

10441044
impl<'a> fmt::Debug for DirectedChannelInfo<'a> {

0 commit comments

Comments
 (0)