mirror of
https://github.com/discourse/discourse.git
synced 2025-03-31 18:55:58 +08:00
FIX: Escape the title of a topic when replying as new
This commit is contained in:
parent
9017a7d2de
commit
914dd2dd8d
@ -427,8 +427,8 @@ export default ObjectController.extend(Discourse.SelectedPostsCount, BufferedCon
|
|||||||
}).then(function() {
|
}).then(function() {
|
||||||
return Em.isEmpty(quotedText) ? Discourse.Post.loadQuote(post.get('id')) : quotedText;
|
return Em.isEmpty(quotedText) ? Discourse.Post.loadQuote(post.get('id')) : quotedText;
|
||||||
}).then(function(q) {
|
}).then(function(q) {
|
||||||
const postUrl = "" + location.protocol + "//" + location.host + (post.get('url')),
|
const postUrl = "" + location.protocol + "//" + location.host + post.get('url'),
|
||||||
postLink = "[" + self.get('title') + "](" + postUrl + ")";
|
postLink = "[" + Handlebars.escapeExpression(self.get('title')) + "](" + postUrl + ")";
|
||||||
composerController.appendText(I18n.t("post.continue_discussion", { postLink: postLink }) + "\n\n" + q);
|
composerController.appendText(I18n.t("post.continue_discussion", { postLink: postLink }) + "\n\n" + q);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user