eth_getStorageAt output hex should begin with 0x

release/1.0.1
Taylor Gerring 10 years ago
parent 3b20603eb1
commit 29930da522
  1. 2
      rpc/api.go

@ -99,7 +99,7 @@ func (api *EthereumApi) GetRequestReply(req *RpcRequest, reply *interface{}) err
state := api.xethAtStateNum(args.BlockNumber).State().SafeGet(args.Address)
value := state.StorageString(args.Key)
*reply = common.Bytes2Hex(value.Bytes())
*reply = common.ToHex(value.Bytes())
case "eth_getTransactionCount":
args := new(GetTxCountArgs)
if err := json.Unmarshal(req.Params, &args); err != nil {

Loading…
Cancel
Save