From 92f1932acbb2d02abcf0aee14d24a232bad83ca0 Mon Sep 17 00:00:00 2001 From: Arnaud Date: Wed, 2 Apr 2025 09:46:10 +0200 Subject: [PATCH] Code style --- ethers/signer.nim | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ethers/signer.nim b/ethers/signer.nim index 5b8f5d3..d3b6b04 100644 --- a/ethers/signer.nim +++ b/ethers/signer.nim @@ -139,11 +139,12 @@ method populateTransaction*( # Multiply by 2 because during times of congestion, baseFeePerGas can increase by 12.5% per block. # https://github.com/ethers-io/ethers.js/discussions/3601#discussioncomment-4461273 - populated.maxFeePerGas = some(transaction.maxFeePerGas |? baseFeePerGas * 2 + maxPriorityFeePerGas) + let maxFeePerGas = transaction.maxFeePerGas |? baseFeePerGas * 2 + maxPriorityFeePerGas + populated.maxFeePerGas = some(maxFeePerGas) populated.gasPrice = none(UInt256) - trace "EIP-1559 is supported", maxPriorityFeePerGas = maxPriorityFeePerGas, maxFeePerGas = populated.maxFeePerGas + trace "EIP-1559 is supported", maxPriorityFeePerGas = maxPriorityFeePerGas, maxFeePerGas = maxFeePerGas else: populated.gasPrice = some(transaction.gasPrice |? (await signer.getGasPrice())) trace "EIP-1559 is not supported", gasPrice = populated.gasPrice