TxResult includes Tx. /tx only works if indexer active

This commit is contained in:
Ethan Buchman
2017-04-18 19:56:41 -04:00
parent d572bb0c5d
commit f4d0076344
12 changed files with 68 additions and 117 deletions

View File

@ -160,13 +160,11 @@ func (c *HTTP) Commit(height int) (*ctypes.ResultCommit, error) {
return (*tmResult).(*ctypes.ResultCommit), nil
}
func (c *HTTP) Tx(hash []byte, height, index int, prove bool) (*ctypes.ResultTx, error) {
func (c *HTTP) Tx(hash []byte, prove bool) (*ctypes.ResultTx, error) {
tmResult := new(ctypes.TMResult)
query := map[string]interface{}{
"height": height,
"index": index,
"hash": hash,
"prove": prove,
"hash": hash,
"prove": prove,
}
_, err := c.rpc.Call("tx", query, tmResult)
if err != nil {