When using JSONRPC, do not double-encode JSON.

This commit is contained in:
Jae Kwon
2015-03-30 15:14:33 -07:00
parent ffa82b5c61
commit 1a4aab4c35
6 changed files with 39 additions and 88 deletions

View File

@ -21,7 +21,7 @@ func TestJSONStatus(t *testing.T) {
s := rpc.JsonRpc{
JsonRpc: "2.0",
Method: "status",
Params: []string{},
Params: []interface{}{},
Id: 0,
}
b, err := json.Marshal(s)
@ -56,7 +56,7 @@ func TestJSONGenPriv(t *testing.T) {
s := rpc.JsonRpc{
JsonRpc: "2.0",
Method: "unsafe/gen_priv_account",
Params: []string{},
Params: []interface{}{},
Id: 0,
}
b, err := json.Marshal(s)