Skip to content

Commit 909bae5

Browse files
committed
Add version note in Confirm docs
While now `ChannelManager` will only return previously confirmed transactions, we can't ensure the same for `ChainMonitor`, as we need to maintain backwards compatibility with version prior to 0.0.113, at which we started tracking the block hash in `ChannelMonitor`s. We therefore add a note to the docs stating that users need to track confirmations on their own for channels created prior to 0.0.113.
1 parent 041c3e6 commit 909bae5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lightning/src/chain/mod.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,9 @@ pub trait Confirm {
176176
/// Returns transactions that must be monitored for reorganization out of the chain along
177177
/// with the hash of the block as part of which it had been previously confirmed.
178178
///
179+
/// Note that the returned `Option<BlockHash>` might be `None` for channels created with LDK
180+
/// 0.0.112 and prior, in which case you need to manually track previous confirmations.
181+
///
179182
/// Will include any transactions passed to [`transactions_confirmed`] that have insufficient
180183
/// confirmations to be safe from a chain reorganization. Will not include any transactions
181184
/// passed to [`transaction_unconfirmed`], unless later reconfirmed.

0 commit comments

Comments
 (0)