reduce blockHash call (#2954)
This commit is contained in:
parent
cd3cea0e29
commit
48aa410f8a
|
@ -41,3 +41,6 @@ nimble.paths
|
||||||
|
|
||||||
# nimbus-build-system files
|
# nimbus-build-system files
|
||||||
nimbus-build-system.paths
|
nimbus-build-system.paths
|
||||||
|
|
||||||
|
# vscode generated files for path mapping into vendor
|
||||||
|
.vscode
|
|
@ -153,8 +153,9 @@ proc validateBlock(c: ForkedChainRef,
|
||||||
if updateCursor:
|
if updateCursor:
|
||||||
c.updateCursor(blk, move(res.value))
|
c.updateCursor(blk, move(res.value))
|
||||||
|
|
||||||
|
let blkHash = blk.header.blockHash
|
||||||
for i, tx in blk.transactions:
|
for i, tx in blk.transactions:
|
||||||
c.txRecords[rlpHash(tx)] = (blk.header.blockHash, uint64(i))
|
c.txRecords[rlpHash(tx)] = (blkHash, uint64(i))
|
||||||
|
|
||||||
ok()
|
ok()
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue