Now json exception listener only works if the request is XMLHTTPRequest