rpc/api: fixed default gas-(price) issue.
This commit is contained in:
@ -333,9 +333,7 @@ func (args *NewTxArgs) UnmarshalJSON(b []byte) (err error) {
|
||||
args.Value = num
|
||||
|
||||
num = nil
|
||||
if ext.Gas == nil {
|
||||
num = big.NewInt(0)
|
||||
} else {
|
||||
if ext.Gas != nil {
|
||||
if num, err = numString(ext.Gas); err != nil {
|
||||
return err
|
||||
}
|
||||
@ -343,9 +341,7 @@ func (args *NewTxArgs) UnmarshalJSON(b []byte) (err error) {
|
||||
args.Gas = num
|
||||
|
||||
num = nil
|
||||
if ext.GasPrice == nil {
|
||||
num = big.NewInt(0)
|
||||
} else {
|
||||
if ext.GasPrice != nil {
|
||||
if num, err = numString(ext.GasPrice); err != nil {
|
||||
return err
|
||||
}
|
||||
|
Reference in New Issue
Block a user