[misc] resolved comments of TODOs

pull/3626/head
Jacky Wang 4 years ago
parent 38b30dc36e
commit e51bdbdc19
No known key found for this signature in database
GPG Key ID: 1085CE5F4FF5842C
  1. 2
      consensus/consensus_v2.go
  2. 1
      node/node_handler.go

@ -711,7 +711,7 @@ func (consensus *Consensus) tryCatchup() error {
return err
}
select {
// TODO(jacky): check if this is still needed.
// TODO: Remove this when removing dns sync and stream sync is fully up
case consensus.VerifiedNewBlock <- blk:
default:
consensus.getLogger().Info().

@ -262,7 +262,6 @@ func (node *Node) VerifyNewBlock(newBlock *types.Block) error {
if newBlock.NumberU64() <= node.Blockchain().CurrentBlock().NumberU64() {
return errors.Errorf("block with the same block number is already committed: %d", newBlock.NumberU64())
}
// TODO(jacky): make sure this uses the cached result from last consensus (if any)
if err := node.Blockchain().Validator().ValidateHeader(newBlock, true); err != nil {
utils.Logger().Error().
Str("blockHash", newBlock.Hash().Hex()).

Loading…
Cancel
Save