mirror of
https://github.com/btcsuite/btcd.git
synced 2025-02-22 22:25:45 +01:00
Merge pull request #2089 from kcalvinalvin/2024-01-03-add-last-flush-time-on-initconsistentstate
blockchain: set the lastflushtime when setting the lastflushhash
This commit is contained in:
commit
13152b35e1
1 changed files with 4 additions and 0 deletions
|
@ -634,6 +634,10 @@ func (b *BlockChain) InitConsistentState(tip *blockNode, interrupt <-chan struct
|
|||
// it to the tip since we checked it's consistent.
|
||||
s.lastFlushHash = tip.hash
|
||||
|
||||
// Set the last flush time as now since we know the state is consistent
|
||||
// at this time.
|
||||
s.lastFlushTime = time.Now()
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue