A platform for community discussion. Free, open, simple.
FIX: theme component setting was not getting updated in the UI (#8247)
Joffrey JAFFEUX88df84bf2b71
diff --git a/app/assets/javascripts/admin/components/theme-setting-editor.js.es6 b/app/assets/javascripts/admin/components/theme-setting-editor.js.es6index 292356d55ae..a99b819466a 100644--- a/app/assets/javascripts/admin/components/theme-setting-editor.js.es6+++ b/app/assets/javascripts/admin/components/theme-setting-editor.js.es6@@ -6,13 +6,16 @@ import { popupAjaxError } from "discourse/lib/ajax-error";export default Component.extend(BufferedContent, SettingComponent, {layoutName: "admin/templates/components/site-setting",- _save() {- return ajax(`/admin/themes/${this.model.id}/setting`, {- type: "PUT",- data: {- name: this.setting.setting,- value: this.get("buffered.value")- }- }).catch(popupAjaxError);++ _save(callback) {+ callback(+ ajax(`/admin/themes/${this.model.id}/setting`, {+ type: "PUT",+ data: {+ name: this.setting.setting,+ value: this.get("buffered.value")+ }+ }).catch(popupAjaxError)+ );}});