FIX: ESC to dismiss empty draft topic composer

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

diff --git a/app/assets/javascripts/discourse/app/models/composer.js b/app/assets/javascripts/discourse/app/models/composer.js
index 56e4d1a..211e4ca 100644
--- a/app/assets/javascripts/discourse/app/models/composer.js
+++ b/app/assets/javascripts/discourse/app/models/composer.js
@@ -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);
     }

GitHub sha: 44712c5f

This commit has been mentioned on Discourse Meta. There might be relevant details there: