Skip to content

Commit 5daf543

Browse files
TheBlueMattjkczyz
andcommitted
Update docs with correct hash type
Co-authored-by: Matt Corallo <[email protected]> Co-authored-by: Jeffrey Czyz <[email protected]>
1 parent d924c7a commit 5daf543

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

lightning/src/chain/channelmonitor.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -620,7 +620,7 @@ impl Readable for ChannelMonitorUpdateStep {
620620
/// reloaded at deserialize-time. Thus, you must ensure that, when handling events, all events
621621
/// gotten are fully handled before re-serializing the new state.
622622
///
623-
/// Note that the deserializer is only implemented for (Sha256dHash, ChannelMonitor), which
623+
/// Note that the deserializer is only implemented for (BlockHash, ChannelMonitor), which
624624
/// tells you the last block hash which was block_connect()ed. You MUST rescan any blocks along
625625
/// the "reorg path" (ie disconnecting blocks until you find a common ancestor from both the
626626
/// returned block hash and the the current chain and then reconnecting blocks to get to the

lightning/src/ln/channelmanager.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,7 @@ pub type SimpleRefChannelManager<'a, 'b, 'c, 'd, 'e, M, T, F, L> = ChannelManage
380380
/// ChannelMonitors passed by reference to read(), those channels will be force-closed based on the
381381
/// ChannelMonitor state and no funds will be lost (mod on-chain transaction fees).
382382
///
383-
/// Note that the deserializer is only implemented for (Sha256dHash, ChannelManager), which
383+
/// Note that the deserializer is only implemented for (BlockHash, ChannelManager), which
384384
/// tells you the last block hash which was block_connect()ed. You MUST rescan any blocks along
385385
/// the "reorg path" (ie call block_disconnected() until you get to a common block and then call
386386
/// block_connected() to step towards your best block) upon deserialization before using the
@@ -3925,8 +3925,8 @@ impl<Signer: Sign, M: Deref, T: Deref, K: Deref, F: Deref, L: Deref> Writeable f
39253925
/// At a high-level, the process for deserializing a ChannelManager and resuming normal operation
39263926
/// is:
39273927
/// 1) Deserialize all stored ChannelMonitors.
3928-
/// 2) Deserialize the ChannelManager by filling in this struct and calling <(Sha256dHash,
3929-
/// ChannelManager)>::read(reader, args).
3928+
/// 2) Deserialize the ChannelManager by filling in this struct and calling:
3929+
/// <(BlockHash, ChannelManager)>::read(reader, args)
39303930
/// This may result in closing some Channels if the ChannelMonitor is newer than the stored
39313931
/// ChannelManager state to ensure no loss of funds. Thus, transactions may be broadcasted.
39323932
/// 3) Register all relevant ChannelMonitor outpoints with your chain watch mechanism using

0 commit comments

Comments
 (0)