aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport
diff options
context:
space:
mode:
authorMichael Koziarski <michael@koziarski.com>2008-10-14 21:23:27 +0200
committerMichael Koziarski <michael@koziarski.com>2008-10-14 21:24:34 +0200
commit3e9fc279e572d440df98fb17d83acd92b66b22dc (patch)
tree713ca7da6c6edd404480a2bf1be027f243559056 /activesupport
parente0993c6c376d62716757a8a7f476ed0c369d0fc7 (diff)
downloadrails-3e9fc279e572d440df98fb17d83acd92b66b22dc.tar.gz
rails-3e9fc279e572d440df98fb17d83acd92b66b22dc.tar.bz2
rails-3e9fc279e572d440df98fb17d83acd92b66b22dc.zip
Avoid warnings by undefining the old method transliterate.
Diffstat (limited to 'activesupport')
-rw-r--r--activesupport/lib/active_support/inflector.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/activesupport/lib/active_support/inflector.rb b/activesupport/lib/active_support/inflector.rb
index 74ca732073..1ccfec4000 100644
--- a/activesupport/lib/active_support/inflector.rb
+++ b/activesupport/lib/active_support/inflector.rb
@@ -279,6 +279,7 @@ module ActiveSupport
# The iconv transliteration code doesn't function correctly
# on some platforms, but it's very fast where it does function.
if "foo" != Inflector.transliterate("föö")
+ undef_method :transliterate
def transliterate(string)
string.mb_chars.normalize(:kd). # Decompose accented characters
gsub(/[^\x00-\x7F]+/, '') # Remove anything non-ASCII entirely (e.g. diacritics).