aboutsummaryrefslogtreecommitdiffstats
path: root/rpc/http.go
diff options
context:
space:
mode:
authorFelix Lange <fjl@twurst.com>2015-03-18 20:39:01 +0800
committerFelix Lange <fjl@twurst.com>2015-03-18 20:39:01 +0800
commitd15f90645d5b2e90c441140972d9fe6ecd753643 (patch)
treeb1f024c3c01f25b67bc25ed0452a9b584dad984f /rpc/http.go
parenta59dd393e71cc52b1f96973aef884af619166f38 (diff)
parent0a1eeca41e6ba5920ba65d9b41654768299bc7e3 (diff)
downloaddexon-d15f90645d5b2e90c441140972d9fe6ecd753643.tar
dexon-d15f90645d5b2e90c441140972d9fe6ecd753643.tar.gz
dexon-d15f90645d5b2e90c441140972d9fe6ecd753643.tar.bz2
dexon-d15f90645d5b2e90c441140972d9fe6ecd753643.tar.lz
dexon-d15f90645d5b2e90c441140972d9fe6ecd753643.tar.xz
dexon-d15f90645d5b2e90c441140972d9fe6ecd753643.tar.zst
dexon-d15f90645d5b2e90c441140972d9fe6ecd753643.zip
Merge remote-tracking branch 'ethereum/conversion' into conversion
Diffstat (limited to 'rpc/http.go')
-rw-r--r--rpc/http.go14
1 files changed, 7 insertions, 7 deletions
diff --git a/rpc/http.go b/rpc/http.go
index 8dcd55ad1..b6edb7cd7 100644
--- a/rpc/http.go
+++ b/rpc/http.go
@@ -26,7 +26,7 @@ func JSONRPC(pipe *xeth.XEth, dataDir string) http.Handler {
if req.ContentLength > maxSizeReqLength {
jsonerr := &RpcErrorObject{-32700, "Request too large"}
- json.Send(w, &RpcErrorResponse{JsonRpc: jsonrpcver, ID: nil, Error: jsonerr})
+ json.Send(w, &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: nil, Error: jsonerr})
return
}
@@ -36,11 +36,11 @@ func JSONRPC(pipe *xeth.XEth, dataDir string) http.Handler {
break
case *DecodeParamError, *InsufficientParamsError, *ValidationError:
jsonerr := &RpcErrorObject{-32602, reqerr.Error()}
- json.Send(w, &RpcErrorResponse{JsonRpc: jsonrpcver, ID: nil, Error: jsonerr})
+ json.Send(w, &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: nil, Error: jsonerr})
return
default:
jsonerr := &RpcErrorObject{-32700, "Could not parse request"}
- json.Send(w, &RpcErrorResponse{JsonRpc: jsonrpcver, ID: nil, Error: jsonerr})
+ json.Send(w, &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: nil, Error: jsonerr})
return
}
@@ -51,19 +51,19 @@ func JSONRPC(pipe *xeth.XEth, dataDir string) http.Handler {
break
case *NotImplementedError:
jsonerr := &RpcErrorObject{-32601, reserr.Error()}
- json.Send(w, &RpcErrorResponse{JsonRpc: jsonrpcver, ID: reqParsed.ID, Error: jsonerr})
+ json.Send(w, &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: reqParsed.Id, Error: jsonerr})
return
case *DecodeParamError, *InsufficientParamsError, *ValidationError:
jsonerr := &RpcErrorObject{-32602, reserr.Error()}
- json.Send(w, &RpcErrorResponse{JsonRpc: jsonrpcver, ID: reqParsed.ID, Error: jsonerr})
+ json.Send(w, &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: reqParsed.Id, Error: jsonerr})
return
default:
jsonerr := &RpcErrorObject{-32603, reserr.Error()}
- json.Send(w, &RpcErrorResponse{JsonRpc: jsonrpcver, ID: reqParsed.ID, Error: jsonerr})
+ json.Send(w, &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: reqParsed.Id, Error: jsonerr})
return
}
rpchttplogger.DebugDetailf("Generated response: %T %s", response, response)
- json.Send(w, &RpcSuccessResponse{JsonRpc: jsonrpcver, ID: reqParsed.ID, Result: response})
+ json.Send(w, &RpcSuccessResponse{Jsonrpc: jsonrpcver, Id: reqParsed.Id, Result: response})
})
}