FELIX-2183 Apply supportjs-ajax-error.patch by Valentin Valchev (thanks)
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@922575 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/webconsole/src/main/resources/res/lib/support.js b/webconsole/src/main/resources/res/lib/support.js
index 67078f0..3687e40 100644
--- a/webconsole/src/main/resources/res/lib/support.js
+++ b/webconsole/src/main/resources/res/lib/support.js
@@ -71,7 +71,9 @@
// register global ajax error handler
$(document).ajaxError( function(event, req) {
- Xalert('The request failed: <br/><pre>' + req.statusText + '</pre>', 'AJAX Error');
+ var text = req.responseXML ? x = req.responseXML :
+ (req.responseText ? x = req.responseText : req.statusText);
+ Xalert('The request failed: <br/><pre>' + text + '</pre>', 'AJAX Error');
});
initStaticWidgets();