From 1427d59f27c42eaeba910bcf19bb6013a89defd1 Mon Sep 17 00:00:00 2001 From: coffeepots Date: Fri, 31 Aug 2018 18:38:17 +0100 Subject: [PATCH] Change setNonce, getNonce to use AccountNonce, which is uint64 from UInt256 --- nimbus/db/state_db.nim | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nimbus/db/state_db.nim b/nimbus/db/state_db.nim index efb3f1579..915a3a941 100644 --- a/nimbus/db/state_db.nim +++ b/nimbus/db/state_db.nim @@ -105,13 +105,13 @@ proc getStorage*(db: AccountStateDB, address: EthAddress, slot: UInt256): (UInt2 else: result = (0.u256, false) -proc setNonce*(db: var AccountStateDB, address: EthAddress, newNonce: UInt256) = +proc setNonce*(db: var AccountStateDB, address: EthAddress, newNonce: AccountNonce) = var account = db.getAccount(address) if newNonce != account.nonce: account.nonce = newNonce db.setAccount(address, account) -proc getNonce*(db: AccountStateDB, address: EthAddress): UInt256 = +proc getNonce*(db: AccountStateDB, address: EthAddress): AccountNonce = let account = db.getAccount(address) account.nonce