mirror of
https://github.com/discourse/discourse.git
synced 2025-02-06 19:38:24 +00:00
FIX: Clear theme editor content on switching tabs
Issue happens when sending a null value to ACE Editor. Fixed by sending an empty string to ACE instead of null.
This commit is contained in:
parent
324e182842
commit
f4dc6de9f1
@ -17,8 +17,9 @@ export default Ember.Component.extend({
|
||||
|
||||
@observes("content")
|
||||
contentChanged() {
|
||||
if (this._editor && !this._skipContentChangeEvent && this.content) {
|
||||
this._editor.getSession().setValue(this.content);
|
||||
const content = this.content || "";
|
||||
if (this._editor && !this._skipContentChangeEvent) {
|
||||
this._editor.getSession().setValue(content);
|
||||
}
|
||||
},
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user