Skip to content

Commit c433473

Browse files
committed
minor fix
1 parent c4d8abf commit c433473

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

miner/worker.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,10 +174,11 @@ func (miner *Miner) prepareWork(genParams *generateParams) (*environment, error)
174174
log.Error("Failed to prepare header for sealing", "err", err)
175175
return nil, err
176176
}
177+
prevArbosVersion := types.DeserializeHeaderExtraInformation(parent).ArbOSFormatVersion
177178
// Apply EIP-4844, EIP-4788.
178-
if miner.chainConfig.IsCancun(header.Number, header.Time, types.DeserializeHeaderExtraInformation(header).ArbOSFormatVersion) {
179+
if miner.chainConfig.IsCancun(header.Number, header.Time, prevArbosVersion) {
179180
var excessBlobGas uint64
180-
if miner.chainConfig.IsCancun(parent.Number, parent.Time, types.DeserializeHeaderExtraInformation(parent).ArbOSFormatVersion) {
181+
if miner.chainConfig.IsCancun(parent.Number, parent.Time, prevArbosVersion) {
181182
excessBlobGas = eip4844.CalcExcessBlobGas(*parent.ExcessBlobGas, *parent.BlobGasUsed)
182183
} else {
183184
// For the first post-fork block, both parent.data_gas_used and parent.excess_data_gas are evaluated as 0

0 commit comments

Comments
 (0)