1
0
Fork 0
mirror of https://github.com/haml/haml.git synced 2022-11-09 12:33:31 -05:00

Merge branch 'stable'

This commit is contained in:
Nathan Weizenbaum 2010-04-11 16:53:26 -07:00
commit c066c987a5
4 changed files with 8 additions and 4 deletions

View file

@ -270,6 +270,8 @@ Thanks to [Josh Peek](http://joshpeek.com/).
* 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).

View file

@ -611,6 +611,9 @@ and the hex representation (shortened to the three-letter version if possible).
{file:SASS_REFERENCE.md#full_exception `:full_exception option`} is enabled,
print the full exception rather than raising it.
* Fix a bug with a weird interaction with Haml, DataMapper, and Rails 3
that caused some tag helpers to go into infinite recursion.
## 2.2.22
[Tagged on GitHub](http://github.com/nex3/haml/commit/2.2.22).

View file

@ -513,7 +513,7 @@ MESSAGE
# @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

View file

@ -125,9 +125,8 @@ module ActionView
@template_object.send :is_haml?
end
unless defined?(ActionView::Helpers) && defined?(ActionView::Helpers::ActiveRecordInstanceTag)
alias_method :content_tag_without_haml, :content_tag
alias_method :content_tag, :content_tag_with_haml
def content_tag(*args)
content_tag_with_haml(*args)
end
end