mirror of
https://github.com/akyaiy/GoSally-mvp.git
synced 2026-01-03 08:32:24 +00:00
add test response using rpc.WriteResponse
This commit is contained in:
@@ -7,7 +7,11 @@ import (
|
||||
)
|
||||
|
||||
func (h *HandlerV1) Handle(w http.ResponseWriter, r *http.Request, req rpc.RPCRequest) {
|
||||
w.Write([]byte("Sigmas"))
|
||||
rpc.WriteResponse(w, &rpc.RPCResponse{
|
||||
JSONRPC: rpc.JSONRPCVersion,
|
||||
ID: req.ID,
|
||||
Result: "Hi",
|
||||
}) // test answer to make sure everything works
|
||||
}
|
||||
|
||||
// func (h *HandlerV1) Handle(w http.ResponseWriter, r *http.Request) {
|
||||
|
||||
Reference in New Issue
Block a user