From 3960b690bf8c67afe706bb469b0ff2798424a26e Mon Sep 17 00:00:00 2001 From: Aaron Buchwald Date: Thu, 17 Dec 2020 13:58:14 -0500 Subject: Decrease minimum gas price at apricot upgrade --- eth/backend.go | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'eth/backend.go') diff --git a/eth/backend.go b/eth/backend.go index e26cbb3..9b6f1e4 100644 --- a/eth/backend.go +++ b/eth/backend.go @@ -559,3 +559,13 @@ func (s *Ethereum) AcceptedBlock() *types.Block { } return s.blockchain.CurrentBlock() } + +// SetGasPrice sets the minimum gas price to [newGasPrice] +// sets the price on [s], [txPool], and the gas price oracle +func (s *Ethereum) SetGasPrice(newGasPrice *big.Int) { + s.lock.Lock() + s.gasPrice = newGasPrice + s.lock.Unlock() + s.txPool.SetGasPrice(newGasPrice) + s.APIBackend.gpo.SetGasPrice(newGasPrice) +} -- cgit v1.2.3