Defect #31021 » 0002-Fullwidth-characters-enclosed-in-lt-and-gt.patch
| lib/redmine/wiki_formatting/textile/redcloth3.rb | ||
|---|---|---|
|
ALLOWED_TAGS = %w(redpre pre code kbd notextile)
|
||
|
def escape_html_tags(text)
|
||
|
text.gsub!(%r{<(\/?([!\w]+)[^<>\n]*)(>?)}) {|m| ALLOWED_TAGS.include?($2) ? "<#{$1}#{$3}" : "<#{$1}#{'>' unless $3.blank?}" }
|
||
|
text.gsub!(%r{<(\/?([!_[[:alnum:]]]+)[^<>\n]*)(>?)}) {|m| ALLOWED_TAGS.include?($2) ? "<#{$1}#{$3}" : "<#{$1}#{'>' unless $3.blank?}" }
|
||
|
end
|
||
|
end
|
||