Okay, so I'm wondering if it possible to get the body of the error. The reason is that sometimes my services return an exception with text I want to display to the user. This will be some kind of business rule validation that is best performed by the web server or the database layer of the application. Something like this.
message:"Delete conflicted with foriegn key constraint FK_XXXXXXXX."
When I look at the Amplify code, I can see on line 566 that it always passes NULL to the error handler function. For me what I'd like to get passed into the error handler is something like JSON.parse(_xhr.responseText). Another developer actually edited the amplify library to allow it to pass through the value here.
I was wondering if you guys had a more elegant idea. Perhaps we are "doing it wrong".