EIP-4844: gasCost regression in validateTx due to rebase conflict mishandled
This commit is contained in:
parent
ab4a1a141b
commit
39402ea8d3
|
@ -300,10 +300,7 @@ proc validateTransaction*(
|
||||||
$tx.maxFee, $tx.maxPriorityFee])
|
$tx.maxFee, $tx.maxPriorityFee])
|
||||||
|
|
||||||
# the signer must be able to fully afford the transaction
|
# the signer must be able to fully afford the transaction
|
||||||
let gasCost = if tx.txType >= TxEip1559:
|
let gasCost = tx.gasCost()
|
||||||
tx.gasLimit.u256 * tx.maxFee.u256
|
|
||||||
else:
|
|
||||||
tx.gasLimit.u256 * tx.gasPrice.u256
|
|
||||||
|
|
||||||
if balance < gasCost:
|
if balance < gasCost:
|
||||||
return err("invalid tx: not enough cash for gas. avail=$1, require=$2" % [
|
return err("invalid tx: not enough cash for gas. avail=$1, require=$2" % [
|
||||||
|
|
Loading…
Reference in New Issue