add fromAddress argument to Call and CallCode rpc methods

This commit is contained in:
Ethan Buchman
2015-07-22 18:43:20 -04:00
parent c13b67253c
commit 290b74d8f1
5 changed files with 27 additions and 26 deletions

View File

@ -4,6 +4,7 @@ import (
rpc "github.com/tendermint/tendermint/rpc/server"
)
// TODO: eliminate redundancy between here and reading code from core/
var Routes = map[string]*rpc.RPCFunc{
"status": rpc.NewRPCFunc(Status, []string{}),
"net_info": rpc.NewRPCFunc(NetInfo, []string{}),
@ -12,8 +13,8 @@ var Routes = map[string]*rpc.RPCFunc{
"get_block": rpc.NewRPCFunc(GetBlock, []string{"height"}),
"get_account": rpc.NewRPCFunc(GetAccount, []string{"address"}),
"get_storage": rpc.NewRPCFunc(GetStorage, []string{"address", "key"}),
"call": rpc.NewRPCFunc(Call, []string{"address", "data"}),
"call_code": rpc.NewRPCFunc(CallCode, []string{"code", "data"}),
"call": rpc.NewRPCFunc(Call, []string{"fromAddress", "toAddress", "data"}),
"call_code": rpc.NewRPCFunc(CallCode, []string{"fromAddress", "code", "data"}),
"list_validators": rpc.NewRPCFunc(ListValidators, []string{}),
"dump_consensus_state": rpc.NewRPCFunc(DumpConsensusState, []string{}),
"dump_storage": rpc.NewRPCFunc(DumpStorage, []string{"address"}),