mirror of
https://github.com/status-im/nimbus-eth2.git
synced 2025-01-22 20:42:13 +00:00
Remove unneeded initialization.
This commit is contained in:
parent
6f4c7b775c
commit
3117a4481e
@ -37,7 +37,9 @@ func shortLog*(x: Eth2Digest): string =
|
||||
|
||||
func eth2hash*(v: openArray[byte]): Eth2Digest =
|
||||
var ctx: Eth2Hash
|
||||
ctx.init()
|
||||
# We can avoid this step for Keccak/SHA3 digests because `ctx` is already
|
||||
# empty, but if digest will be changed next line must be enabled.
|
||||
# ctx.init()
|
||||
ctx.update(v)
|
||||
result = ctx.finish()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user