Add detailed info on error for NextMsg() request

Signed-off-by: Derek Collison <derek@nats.io>
This commit is contained in:
Derek Collison
2020-10-21 11:26:22 -07:00
parent 3b18f188ed
commit df29f1fb50

View File

@@ -1190,7 +1190,7 @@ func (o *Consumer) processNextMsgReq(_ *subscription, c *client, _, reply string
// Check payload here to see if they sent in batch size or a formal request.
expires, batchSize, noWait, err := nextReqFromMsg(msg)
if err != nil {
sendErr(400, "Bad Request")
sendErr(400, fmt.Sprintf("Bad Request - %v", err))
return
}