ArcBees / gwtquery

A jQuery clone for GWT, and much more.
MIT License
85 stars 38 forks source link

Ajax request onError missing response argument #284

Open heyarny opened 10 years ago

heyarny commented 10 years ago

I'd like to access the response object within the failure callback. In case I want to create my own Exception out of the statusCode and statusText there are no arguments or ways to get the response object.

The Exception created by Ajax does not meet my requirements as it creates a hardcoded predefined message with the whole html/text response.

pharacyde commented 9 years ago

we are having the same issue. We are interested in the JSON payload from our REST Service, as it contains the description why the request failed.

jDramaix commented 9 years ago

Inside your Function instance, call:

Response response = arguments(3);
jDramaix commented 9 years ago

Sorry I didn't see that your question was about the failure callback.

Indeed it seems that we don't propagate the request on error.