jsend
jsend copied to clipboard
including optional "message" field for "fail" status
We usually send "fail" status if validation errors exist with request data. Sometimes, the failed message may not be included with any key of request payload(for example: when the input data is included in request parameters, instead of request body). In such situations, adding an optional "message" field with response( just like in error condition) would make this standard even more flexible.
I'd like to see this change as well -- @xzilla what are your thoughts on this? It was also brought up in #9
That would be the best implementation. Actually, maybe consider adding a message as a standard. Just sending error or data with no description...