mirror of
https://github.com/discourse/discourse.git
synced 2025-06-06 13:06:56 +08:00
FIX: ESC to dismiss empty draft topic composer
Previously originalTitle was set to undefined leading to titleDirty being unconditionally undefined for new topics That mean you could not dismiss the composer via ESC
This commit is contained in:
@ -785,11 +785,14 @@ const Composer = RestModel.extend({
|
||||
});
|
||||
}
|
||||
|
||||
this.set("originalTitle", "");
|
||||
|
||||
if (opts.title) {
|
||||
this.set("title", opts.title);
|
||||
}
|
||||
|
||||
this.set("originalText", opts.draft ? "" : this.reply);
|
||||
|
||||
if (this.editingFirstPost) {
|
||||
this.set("originalTitle", this.title);
|
||||
}
|
||||
|
Reference in New Issue
Block a user