good morning!!!!

Skip to content
Snippets Groups Projects
Commit 6e212bdc authored by Zsolt Felföldi's avatar Zsolt Felföldi
Browse files

fallback for uninitialized GPO config values

parent 2e8016c8
Branches
Tags
No related merge requests found
...@@ -162,6 +162,9 @@ func (self *GasPriceOracle) SuggestPrice() *big.Int { ...@@ -162,6 +162,9 @@ func (self *GasPriceOracle) SuggestPrice() *big.Int {
if base == nil { if base == nil {
base = self.eth.GpoMinGasPrice base = self.eth.GpoMinGasPrice
} }
if base == nil {
return big.NewInt(10000000000000) // apparently MinGasPrice is not initialized during some tests
}
baseCorr := new(big.Int).Mul(base, big.NewInt(int64(100+self.eth.GpobaseCorrectionFactor))) baseCorr := new(big.Int).Mul(base, big.NewInt(int64(100+self.eth.GpobaseCorrectionFactor)))
baseCorr.Div(baseCorr, big.NewInt(100)) baseCorr.Div(baseCorr, big.NewInt(100))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment