diff --git a/lib/blockchain.go b/lib/blockchain.go index 9ef607518..37c1fe95c 100644 --- a/lib/blockchain.go +++ b/lib/blockchain.go @@ -584,6 +584,7 @@ func NewBlockIndex(db *badger.DB, snapshot *Snapshot, tipNode *BlockNode) *Block snapshot: snapshot, blockIndexByHash: blockIndexByHash, tip: tipNode, + headerTip: tipNode, } } diff --git a/lib/server.go b/lib/server.go index c3269c875..fa067edee 100644 --- a/lib/server.go +++ b/lib/server.go @@ -1126,9 +1126,6 @@ func (srv *Server) shouldVerifySignatures(header *MsgDeSoHeader, isHeaderChain b if checkpointBlockInfo == nil { return true, false } - // TODO: @diamondhands - why can't we move this up in this function? It seems like we can avoid - // checking if we have the checkpoint block node if the header we're processing is below the height. - // This will save us 17-18% of the time it takes to process headers. // If the current header has a height below the checkpoint block height, we should skip signature verification // even if we've seen the checkpoint block hash. if header.Height < checkpointBlockInfo.Height {