mirror of https://github.com/status-im/op-geth.git
optimism: user can set pending block gas limit (#24)
This commit is contained in:
parent
ac785740c5
commit
ffcd75be7d
|
@ -1040,6 +1040,9 @@ func (w *worker) prepareWork(genParams *generateParams) (*environment, error) {
|
|||
}
|
||||
if genParams.gasLimit != nil { // override gas limit if specified
|
||||
header.GasLimit = *genParams.gasLimit
|
||||
} else if w.chain.Config().Optimism != nil && w.config.GasCeil != 0 {
|
||||
// configure the gas limit of pending blocks with the miner gas limit config when using optimism
|
||||
header.GasLimit = w.config.GasCeil
|
||||
}
|
||||
// Run the consensus preparation with the default or customized consensus engine.
|
||||
if err := w.engine.Prepare(w.chain, header); err != nil {
|
||||
|
|
Loading…
Reference in New Issue