FELIX-3116 : Saving configuration shows "AJAX error" dialog
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@1170981 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/webconsole/src/main/resources/res/ui/config.js b/webconsole/src/main/resources/res/ui/config.js
index 04cd0ce..8b93e7e 100644
--- a/webconsole/src/main/resources/res/ui/config.js
+++ b/webconsole/src/main/resources/res/ui/config.js
@@ -535,9 +535,11 @@
unbindConfig($(this).attr('__pid'), $(this).attr('__location'));
}
_buttons[i18n.save] = function() {
- $.post(pluginRoot + '/' + $(this).attr('__pid') + '?' + $(this).find('form').serialize());
+ $.post(pluginRoot + '/' + $(this).attr('__pid') + '?' + $(this).find('form').serialize(), function() {
+ // reload on success - prevents AJAX errors - see FELIX-3116
+ document.location.href = pluginRoot;
+ });
$(this).dialog('close');
- document.location.href = pluginRoot;
}
// prepare editor, but don't open yet!
editor = $('#editor').dialog({