aboutsummaryrefslogtreecommitdiffstats
path: root/rpc
diff options
context:
space:
mode:
Diffstat (limited to 'rpc')
-rw-r--r--rpc/api.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/rpc/api.go b/rpc/api.go
index 66283752b..b23a9be15 100644
--- a/rpc/api.go
+++ b/rpc/api.go
@@ -189,7 +189,11 @@ func (api *EthereumApi) GetRequestReply(req *RpcRequest, reply *interface{}) err
return err
}
// TODO unwrap the parent method's ToHex call
- *reply = newHexData(common.FromHex(v))
+ if v == "0x0" {
+ *reply = newHexData([]byte{})
+ } else {
+ *reply = newHexData(common.FromHex(v))
+ }
case "eth_flush":
return NewNotImplementedError(req.Method)
case "eth_getBlockByHash":