diff --git a/core/celo_multi_gaspool.go b/core/celo_multi_gaspool.go index b1201470a4..3eee0be536 100644 --- a/core/celo_multi_gaspool.go +++ b/core/celo_multi_gaspool.go @@ -1,9 +1,6 @@ package core import ( - // "fmt" - // "math" - "github.com/celo-org/celo-blockchain/common" ) @@ -19,6 +16,8 @@ type MultiGasPool struct { type FeeCurrencyLimitMapping = map[FeeCurrency]float64 +// NewMultiGasPool creates a multi-fee currency gas pool and a default fallback +// pool for any unconfigured currencies and CELO func NewMultiGasPool( block_gas_limit uint64, whitelist []FeeCurrency, @@ -48,6 +47,8 @@ func NewMultiGasPool( } } +// PoolFor returns a configured pool for the given fee currency or the default +// one otherwise func (mgp MultiGasPool) PoolFor(feeCurrency *FeeCurrency) *GasPool { if feeCurrency == nil || mgp.pools[*feeCurrency] == nil { return mgp.defaultPool