mirror of
https://github.com/discourse/discourse.git
synced 2025-01-19 11:12:46 +08:00
Sanitize your bio after you save it and render it to yourself.
This commit is contained in:
parent
7c8ea8c166
commit
09ed7fe283
|
@ -63,7 +63,7 @@ Discourse.PreferencesController = Discourse.ObjectController.extend({
|
||||||
if (Discourse.User.currentProp('id') === model.get('id')) {
|
if (Discourse.User.currentProp('id') === model.get('id')) {
|
||||||
Discourse.User.currentProp('name', model.get('name'));
|
Discourse.User.currentProp('name', model.get('name'));
|
||||||
}
|
}
|
||||||
self.set('bio_cooked', Discourse.Markdown.cook(self.get('bio_raw')));
|
self.set('bio_cooked', Discourse.Markdown.cook(Discourse.Markdown.sanitize(self.get('bio_raw'))));
|
||||||
self.set('saved', true);
|
self.set('saved', true);
|
||||||
}, function() {
|
}, function() {
|
||||||
// model failed to save
|
// model failed to save
|
||||||
|
|
Loading…
Reference in New Issue
Block a user