- /// Returns a [`DirectedChannelInfo`] for the channel directed to the given `target`, or `None`
- /// if `target` is not one of the channel's counterparties.
- pub fn as_directed_to(&self, target: &NodeId) -> Option<DirectedChannelInfo> {
- let (direction, source, target) = {
+ /// 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)> {
+ let (direction, source) = {