Don't double-up on #main-outlet when static content is rendered through Ember

This commit is contained in:
tms
2013-03-03 10:47:40 -05:00
parent dfafadfe41
commit f46c819956
2 changed files with 4 additions and 1 deletions
@@ -18,7 +18,8 @@ Discourse.StaticController = Discourse.Controller.extend({
$preloaded = $("noscript[data-path=\"" + path + "\"]");
if ($preloaded.length) {
text = $preloaded.text();
text = text.replace(/<header[\s\S]*<\/header\>/, '');
text = text.match(/<!-- preload-content: -->((?:.|[\n\r])*)<!-- :preload-content -->/);
text = text[1];
return this.set('content', text);
} else {
return jQuery.ajax({