File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -570,14 +570,10 @@ func (account *Account) newTx(
570570 }
571571 }
572572 }
573- gasLimit := uint64 (21000 ) // gas limit for standard ethereum transactions
574- if account .coin .erc20Token != nil {
575- n , err := account .coin .client .EstimateGas (context .TODO (), message )
576- if err != nil {
577- account .log .WithError (err ).Error ("Could not estimate the gas limit." )
578- return nil , errp .WithStack (errors .ErrInvalidData )
579- }
580- gasLimit = n
573+ gasLimit , err := account .coin .client .EstimateGas (context .TODO (), message )
574+ if err != nil {
575+ account .log .WithError (err ).Error ("Could not estimate the gas limit." )
576+ return nil , errp .WithStack (errors .ErrInvalidData )
581577 }
582578
583579 fee := new (big.Int ).Mul (new (big.Int ).SetUint64 (gasLimit ), suggestedGasPrice )
You can’t perform that action at this time.
0 commit comments