From 7c1386d928acd050684f435e49149696bcc0a637 Mon Sep 17 00:00:00 2001 From: Bojie Wu Date: Tue, 9 Oct 2018 13:28:45 +0800 Subject: app: add cache mechanism to increase performance --- consensus/dexcon/dexcon.go | 2 ++ 1 file changed, 2 insertions(+) (limited to 'consensus/dexcon/dexcon.go') diff --git a/consensus/dexcon/dexcon.go b/consensus/dexcon/dexcon.go index d8c181432..67bf33bbf 100644 --- a/consensus/dexcon/dexcon.go +++ b/consensus/dexcon/dexcon.go @@ -113,6 +113,8 @@ func (d *Dexcon) Finalize(chain consensus.ChainReader, header *types.Header, sta config := d.configFetcher.DexconConfiguration(header.Round) reward := new(big.Int).Div(config.BlockReward, big.NewInt(int64(config.NumChains))) state.AddBalance(header.Coinbase, reward) + + header.BlockReward = reward header.Root = state.IntermediateRoot(true) return types.NewBlock(header, txs, uncles, receipts), nil } -- cgit v1.2.3