|
|
@ -60,8 +60,8 @@ func (s *PublicHarmonyService) Syncing( |
|
|
|
// Note that the return type is an interface to account for the different versions
|
|
|
|
// Note that the return type is an interface to account for the different versions
|
|
|
|
func (s *PublicHarmonyService) GasPrice(ctx context.Context) (interface{}, error) { |
|
|
|
func (s *PublicHarmonyService) GasPrice(ctx context.Context) (interface{}, error) { |
|
|
|
price, err := s.hmy.SuggestPrice(ctx) |
|
|
|
price, err := s.hmy.SuggestPrice(ctx) |
|
|
|
if err != nil || price.Cmp(big.NewInt(5e10)) < 0 { |
|
|
|
if err != nil || price.Cmp(big.NewInt(3e10)) < 0 { |
|
|
|
price = big.NewInt(5e10) |
|
|
|
price = big.NewInt(3e10) |
|
|
|
} |
|
|
|
} |
|
|
|
// Format response according to version
|
|
|
|
// Format response according to version
|
|
|
|
switch s.version { |
|
|
|
switch s.version { |
|
|
|