good morning!!!!

Skip to content
Snippets Groups Projects
Commit c8e9abff authored by Taylor Gerring's avatar Taylor Gerring
Browse files

Remove errParseRequest

parent 43acad81
No related branches found
No related tags found
No related merge requests found
......@@ -92,7 +92,7 @@ func (s *RpcHttpServer) apiHandler(api *rpc.EthereumApi) http.Handler {
reqParsed, reqerr := JSON.ParseRequestBody(req)
if reqerr != nil {
jsonerr := &rpc.RpcErrorObject{-32700, rpc.ErrorParseRequest}
jsonerr := &rpc.RpcErrorObject{-32700, "Error: Could not parse request"}
JSON.Send(w, &rpc.RpcErrorResponse{JsonRpc: jsonrpcver, ID: nil, Error: jsonerr})
return
}
......
......@@ -29,7 +29,6 @@ var (
errArguments = errors.New("Error: Insufficient arguments")
errNotImplemented = errors.New("Error: Method not implemented")
errUnknown = errors.New("Error: Unknown error")
errParseRequest = errors.New("Error: Could not parse request")
errDecodeArgs = errors.New("Error: Could not decode arguments")
)
......
......@@ -99,7 +99,7 @@ func sockHandler(api *rpc.EthereumApi) websocket.Handler {
// reqParsed, reqerr := JSON.ParseRequestBody(conn.Request())
if err := websocket.JSON.Receive(conn, &reqParsed); err != nil {
jsonerr := &rpc.RpcErrorObject{-32700, rpc.ErrorParseRequest}
jsonerr := &rpc.RpcErrorObject{-32700, "Error: Could not parse request"}
JSON.Send(conn, &rpc.RpcErrorResponse{JsonRpc: jsonrpcver, ID: nil, Error: jsonerr})
continue
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment