diff --git a/nimbus/vm/state_transactions.nim b/nimbus/vm/state_transactions.nim index b19f1ee6f..c109d9c2a 100644 --- a/nimbus/vm/state_transactions.nim +++ b/nimbus/vm/state_transactions.nim @@ -8,7 +8,7 @@ import options, sets, eth/common, chronicles, ../db/accounts_cache, - ../transaction, + ../transaction, ../forks, ./computation, ./interpreter, ./state, ./types proc execComputation*(c: Computation) = @@ -19,7 +19,9 @@ proc execComputation*(c: Computation) = c.execCallOrCreate() if c.isSuccess: - c.refundSelfDestruct() + if c.fork < FkLondon: + # EIP-3529: Reduction in refunds + c.refundSelfDestruct() shallowCopy(c.vmState.selfDestructs, c.selfDestructs) shallowCopy(c.vmState.logEntries, c.logEntries) c.vmState.touchedAccounts.incl c.touchedAccounts diff --git a/nimbus/vm2/state_transactions.nim b/nimbus/vm2/state_transactions.nim index 18ff4fa0d..97e4e84bc 100644 --- a/nimbus/vm2/state_transactions.nim +++ b/nimbus/vm2/state_transactions.nim @@ -89,7 +89,9 @@ proc execComputation*(c: Computation) = c.execCallOrCreate() if c.isSuccess: - c.refundSelfDestruct() + if c.fork < FkLondon: + # EIP-3529: Reduction in refunds + c.refundSelfDestruct() shallowCopy(c.vmState.selfDestructs, c.selfDestructs) shallowCopy(c.vmState.logEntries, c.logEntries) c.vmState.touchedAccounts.incl c.touchedAccounts