FIX: prepend 'continue discussion' link to topic template

This commit is contained in:
Arpit Jalan
2016-05-03 14:37:57 +05:30
parent 44868c9e77
commit 706ea28ef9
3 changed files with 25 additions and 1 deletions
@@ -360,6 +360,15 @@ const Composer = RestModel.extend({
return before.length + text.length;
},
prependText(text, opts) {
const reply = (this.get('reply') || '');
if (opts && opts.new_line && reply.length > 0) {
text = text.trim() + "\n\n";
}
this.set('reply', text + reply);
},
applyTopicTemplate(oldCategoryId, categoryId) {
if (this.get('action') !== CREATE_TOPIC) { return; }
let reply = this.get('reply');