mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-30 19:08:10 -05:00
Fix Post-rendering bug
Ember.Handlebars.normalizePath was being called with an object as argument which caused it to error out. also wrapped the return in a SafeString, so the html will not get escaped again.
This commit is contained in:
parent
23a17bd76d
commit
a9d34c3589
1 changed files with 3 additions and 2 deletions
|
@ -7,9 +7,10 @@
|
|||
Handlebars.registerHelper('breakUp', function(property, hint, options) {
|
||||
var prop = Ember.Handlebars.get(this, property, options);
|
||||
if (!prop) return "";
|
||||
hint = Ember.Handlebars.get(this, hint, options);
|
||||
if (typeof(hint) !== 'string') hint = property;
|
||||
|
||||
return Discourse.Formatter.breakUp(prop, hint);
|
||||
hint = Ember.Handlebars.get(this, hint, options);
|
||||
return new Handlebars.SafeString(Discourse.Formatter.breakUp(prop, hint));
|
||||
});
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue