Skip to content

Commit 4dce6b4

Browse files
committed
better docs comments
1 parent a982472 commit 4dce6b4

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lightning/src/util/events.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,9 @@ pub enum ClosureReason {
130130
///
131131
/// Be careful about printing the peer_msg, a well-crafted message could exploit
132132
/// a security vulnerability in the terminal emulator or the logging subsystem.
133-
/// To be safe, use Display on CounterpartyForceClosedPeerMsg (it is sanitized)
133+
/// To be safe, use `Display` on `CounterpartyForceClosedPeerMsg` (it is sanitized)
134+
///
135+
/// [`CounterpartyForceClosedPeerMsg`]: CounterpartyForceClosedPeerMsg
134136
peer_msg: CounterpartyForceClosedPeerMsg,
135137
},
136138
/// Closure generated from [`ChannelManager::force_close_channel`], called by the user.
@@ -204,7 +206,7 @@ impl_writeable_tlv_based_enum_upgradable!(ClosureReason,
204206
(12, OutdatedChannelManager) => {},
205207
);
206208

207-
/// Struct to Display the CounterpartyForceClosed peer_msg using PrintableString
209+
/// Struct to `Display` `CounterpartyForceClosed::peer_msg` using `PrintableString`
208210
/// Print the peer_msg using Display to sanitize it (remove control characters)
209211
#[derive(Clone, Debug, PartialEq, Eq)]
210212
pub struct CounterpartyForceClosedPeerMsg(pub String);

0 commit comments

Comments
 (0)