Skip to content

Commit

Permalink
mention xml_escape in deprecation warning
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Jan 14, 2013
1 parent cec5010 commit 20f254c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
5 changes: 3 additions & 2 deletions Changes
@@ -1,7 +1,8 @@

3.80 2013-01-14
- Deprecated Mojo::Util->html_escape.
- Deprecated Mojo::ByteStream->html_escape.
- Deprecated Mojo::Util->html_escape in favor of Mojo::Util->xml_escape.
- Deprecated Mojo::ByteStream->html_escape in favor of
Mojo::ByteStream->xml_escape.
- Fixed support for multi byte entities in Mojo::Util.

3.79 2013-01-13
Expand Down
4 changes: 3 additions & 1 deletion lib/Mojo/Util.pm
Expand Up @@ -117,7 +117,9 @@ sub hmac_sha1_sum { _hmac(\&sha1, @_) }
# DEPRECATED in Rainbow!
sub html_escape {
warn "Mojo::Util->html_escape is DEPRECATED!\n";
warn <<EOF;
Mojo::Util->html_escape is DEPRECATED in favor of Mojo::Util->xml_escape!!!
EOF
my ($string, $pattern) = @_;
$pattern ||= '^\n\r\t !#$%(-;=?-~';
return $string unless $string =~ /[^$pattern]/;
Expand Down

0 comments on commit 20f254c

Please sign in to comment.