Remove unnecessary nil check (#4952)

Nil slices are always 0-length.
This commit is contained in:
Hyung-Kyu Hqueue Choi 2019-08-26 21:05:43 +09:00 committed by Alessio Treglia
parent 1a15f68359
commit d3aa9feaca
1 changed files with 1 additions and 1 deletions

View File

@ -786,7 +786,7 @@ func (app *BaseApp) DeliverTx(req abci.RequestDeliverTx) (res abci.ResponseDeliv
// validateBasicTxMsgs executes basic validator calls for messages. // validateBasicTxMsgs executes basic validator calls for messages.
func validateBasicTxMsgs(msgs []sdk.Msg) sdk.Error { func validateBasicTxMsgs(msgs []sdk.Msg) sdk.Error {
if msgs == nil || len(msgs) == 0 { if len(msgs) == 0 {
return sdk.ErrUnknownRequest("Tx.GetMsgs() must return at least one message in list") return sdk.ErrUnknownRequest("Tx.GetMsgs() must return at least one message in list")
} }