fix issue with escaping < in dtext

This commit is contained in:
albert
2013-02-24 16:56:45 -05:00
parent 57ea02bc5b
commit 1e758a7f7f
2 changed files with 3 additions and 1 deletions

View File

@@ -451,7 +451,7 @@ Danbooru.Note = {
$article.data("y"),
$article.data("width"),
$article.data("height"),
$article.html()
$article.text()
);
});
}

View File

@@ -190,6 +190,8 @@ class DText
end
def self.sanitize(text)
text.gsub!(/<( |\Z)/, "&lt;\\1")
Sanitize.clean(
text,
:elements => %w(tn h1 h2 h3 h4 h5 h6 a span div blockquote br p ul li ol em strong small big b i font),