parent
58b3d67600
commit
7dc2360c8b
|
@ -10,6 +10,8 @@
|
|||
|
||||
* Don't remove `\n` in filters with interpolation.
|
||||
|
||||
* Silence those annoying `"regexp match /.../n against to UTF-8 string"` warnings.
|
||||
|
||||
## 2.2.22
|
||||
|
||||
[Tagged on GitHub](http://github.com/nex3/haml/commit/2.2.22).
|
||||
|
|
|
@ -502,7 +502,7 @@ END
|
|||
# @param text [String] The string to sanitize
|
||||
# @return [String] The sanitized string
|
||||
def html_escape(text)
|
||||
text.to_s.gsub(/[\"><&]/n) {|s| HTML_ESCAPE[s]}
|
||||
Haml::Util.silence_warnings {text.to_s.gsub(/[\"><&]/n) {|s| HTML_ESCAPE[s]}}
|
||||
end
|
||||
|
||||
# Escapes HTML entities in `text`, but without escaping an ampersand
|
||||
|
|
Loading…
Reference in New Issue