mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-17 18:30:45 +00:00
fix unittest
This commit is contained in:
parent
0cb5dbc04d
commit
7ca3b22aa8
1 changed files with 5 additions and 3 deletions
|
|
@ -507,8 +507,10 @@ func (bc *BlockChain) insert(block *types.Block) {
|
||||||
bc.currentBlock.Store(block)
|
bc.currentBlock.Store(block)
|
||||||
|
|
||||||
// save cache BlockSigners
|
// save cache BlockSigners
|
||||||
engine := bc.Engine().(*XDPoS.XDPoS)
|
if bc.chainConfig.XDPoS != nil {
|
||||||
engine.CacheData(block.Header(), block.Transactions(), bc.GetReceiptsByHash(block.Hash()))
|
engine := bc.Engine().(*XDPoS.XDPoS)
|
||||||
|
engine.CacheData(block.Header(), block.Transactions(), bc.GetReceiptsByHash(block.Hash()))
|
||||||
|
}
|
||||||
|
|
||||||
// If the block is better than our head or is on a different chain, force update heads
|
// If the block is better than our head or is on a different chain, force update heads
|
||||||
if updateHeads {
|
if updateHeads {
|
||||||
|
|
@ -1828,7 +1830,7 @@ func (bc *BlockChain) UpdateM1() error {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
addr := common.HexToAddress(common.MasternodeVotingSMC)
|
addr := common.HexToAddress(common.MasternodeVotingSMC)
|
||||||
validator, err := contractValidator.NewTomoValidator(addr, client)
|
validator, err := contractValidator.NewXDCValidator(addr, client)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue