X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Fchain%2Fchannelmonitor.rs;h=855263fe53b9bd09ce0f6bbbd64beabc34db64d5;hb=28c9b56113ff1ebb1b505a2c979c55c1626aa06b;hp=38dcd6cf0e70daf2457800fc8fc3d7ee68d16247;hpb=f0b818952bd4da666310bacfad9321a5da995c29;p=rust-lightning diff --git a/lightning/src/chain/channelmonitor.rs b/lightning/src/chain/channelmonitor.rs index 38dcd6cf..855263fe 100644 --- a/lightning/src/chain/channelmonitor.rs +++ b/lightning/src/chain/channelmonitor.rs @@ -1214,7 +1214,11 @@ impl ChannelMonitor { self.inner.lock().unwrap().get_cur_holder_commitment_number() } - pub(crate) fn get_counterparty_node_id(&self) -> Option { + /// Gets the `node_id` of the counterparty for this channel. + /// + /// Will be `None` for channels constructed on LDK versions prior to 0.0.110 and always `Some` + /// otherwise. + pub fn get_counterparty_node_id(&self) -> Option { self.inner.lock().unwrap().counterparty_node_id }