Skip to content

Commit ccdbac4

Browse files
committed
Expose the constants mentioned in docs, and use doc links
1 parent 2cb5b1a commit ccdbac4

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

lightning/src/ln/channelmanager.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -510,7 +510,11 @@ impl<'a> Drop for PersistenceNotifierGuard<'a> {
510510

511511
/// The amount of time in blocks we require our counterparty wait to claim their money (ie time
512512
/// between when we, or our watchtower, must check for them having broadcast a theft transaction).
513-
pub(crate) const BREAKDOWN_TIMEOUT: u16 = 6 * 24;
513+
///
514+
/// This can be incrased (but not decreased) through [`ChannelHandshakeConfig::our_to_self_delay`]
515+
///
516+
/// [`ChannelHandshakeConfig::our_to_self_delay`]: `crate::util::config::ChannelHandshakeConfig::our_to_self_delay`
517+
pub const BREAKDOWN_TIMEOUT: u16 = 6 * 24;
514518
/// The amount of time in blocks we're willing to wait to claim money back to us. This matches
515519
/// the maximum required amount in lnd as of March 2021.
516520
pub(crate) const MAX_LOCAL_BREAKDOWN_TIMEOUT: u16 = 2 * 6 * 24 * 7;

lightning/src/util/config.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ pub struct ChannelHandshakeConfig {
3333
/// case of an honest unilateral channel close, which implicitly decrease the economic value of
3434
/// our channel.
3535
///
36-
/// Default value: BREAKDOWN_TIMEOUT (currently 144), we enforce it as a minimum at channel
36+
/// Default value: [`BREAKDOWN_TIMEOUT`] (currently 144), we enforce it as a minimum at channel
3737
/// opening so you can tweak config to ask for more security, not less.
3838
pub our_to_self_delay: u16,
3939
/// Set to the smallest value HTLC we will accept to process.

0 commit comments

Comments
 (0)