Skip to content

Commit bc3712e

Browse files
committed
修正升级 Rails 以后 sanitize_markdown 函数过滤错误的问题;
@chloerei 为何之前会改成两次 sanitize 调用?然后 Rails 4.2.5.1 这次对 rails-html-sanitizer 的安全修复是否解决了之前你修正那个问题?
1 parent 00aa7c5 commit bc3712e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/helpers/application_helper.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ module ApplicationHelper
88

99
def sanitize_markdown(body)
1010
# TODO: This method slow, 3.5ms per call in topic body
11-
sanitize sanitize(body, tags: ALLOW_TAGS, attributes: ALLOW_ATTRIBUTES)
11+
sanitize(body, tags: ALLOW_TAGS, attributes: ALLOW_ATTRIBUTES)
1212
end
1313

1414
def notice_message

0 commit comments

Comments
 (0)