linting: apply errcheck part1

This commit is contained in:
Zach Ramsay
2017-09-06 11:50:43 -04:00
committed by Ethan Buchman
parent d95ba866b8
commit 57ea4987f7
25 changed files with 272 additions and 81 deletions

View File

@ -270,14 +270,18 @@ func (s *State) indexTxs(abciResponses *ABCIResponses) {
batch := txindex.NewBatch(len(abciResponses.DeliverTx))
for i, d := range abciResponses.DeliverTx {
tx := abciResponses.txs[i]
batch.Add(types.TxResult{
if err := batch.Add(types.TxResult{
Height: uint64(abciResponses.Height),
Index: uint32(i),
Tx: tx,
Result: *d,
})
}); err != nil {
panic(err)
}
}
if err := s.TxIndexer.AddBatch(batch); err != nil {
panic(err)
}
s.TxIndexer.AddBatch(batch)
}
// ExecCommitBlock executes and commits a block on the proxyApp without validating or mutating the state.