NatSpec, URL register storage retrieval
fixed 2/3 tests
This commit is contained in:
11
rpc/api.go
11
rpc/api.go
@ -2,7 +2,7 @@ package rpc
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
// "fmt"
|
||||
"fmt"
|
||||
"math/big"
|
||||
"sync"
|
||||
|
||||
@ -167,6 +167,15 @@ func (api *EthereumApi) GetRequestReply(req *RpcRequest, reply *interface{}) err
|
||||
return err
|
||||
}
|
||||
|
||||
// call ConfirmTransaction first
|
||||
var obj []json.RawMessage
|
||||
if err := json.Unmarshal(req.Params, &obj); err != nil {
|
||||
return NewDecodeParamError(err.Error())
|
||||
}
|
||||
if !api.xeth().ConfirmTransaction(string(obj[0])) {
|
||||
return fmt.Errorf("Transaction not confirmed")
|
||||
}
|
||||
|
||||
v, err := api.xeth().Transact(args.From, args.To, args.Value.String(), args.Gas.String(), args.GasPrice.String(), args.Data)
|
||||
if err != nil {
|
||||
return err
|
||||
|
Reference in New Issue
Block a user