Skip to content

Commit 8049f94

Browse files
committed
Fix and improve
1 parent 6d58a8d commit 8049f94

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

src/Nethermind/Nethermind.Consensus/Validators/BlockValidator.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ private bool ValidateTransactionsDataGas(Block block, IReleaseSpec spec, out str
224224
continue;
225225
}
226226

227-
if (transaction.MaxFeePerDataGas < (dataGasPrice ??= IntrinsicGasCalculator.CalculateDataGasPrice(block.Header)))
227+
if (transaction.MaxFeePerDataGas < (dataGasPrice ??= IntrinsicGasCalculator.CalculateDataGasPricePerUnit(block.Header)))
228228
{
229229
error = $"A transaction has unsufficient MaxFeePerDataGas {transaction.MaxFeePerDataGas} < {dataGasPrice}.";
230230
if (_logger.IsWarn) _logger.Warn(error);

src/Nethermind/Nethermind.Core/Transaction.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,8 @@ public string ToString(string indent)
173173

174174
if (SupportsBlobs)
175175
{
176-
builder.AppendLine($"{indent}BlobVersionedHashes: {BlobVersionedHashes?.Length}");
176+
builder.AppendLine($"{indent}{nameof(MaxFeePerDataGas)}: {MaxFeePerDataGas}");
177+
builder.AppendLine($"{indent}{nameof(BlobVersionedHashes)}: {BlobVersionedHashes?.Length}");
177178
}
178179

179180
return builder.ToString();

0 commit comments

Comments
 (0)