diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2008-04-20 16:49:58 -0700 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2008-04-20 16:49:58 -0700 |
commit | 59f5d4fc79b72a2bf0f7ffada4a1a73eb303d943 (patch) | |
tree | 994c441f880ef4f8e739eeac58bda8a5c60614a9 /activesupport | |
parent | 3b93ca221d3a1b777bd880c18f52010cbd56c18c (diff) | |
download | rails-59f5d4fc79b72a2bf0f7ffada4a1a73eb303d943.tar.gz rails-59f5d4fc79b72a2bf0f7ffada4a1a73eb303d943.tar.bz2 rails-59f5d4fc79b72a2bf0f7ffada4a1a73eb303d943.zip |
Use append_features instead of included to get the inclusion order right
Diffstat (limited to 'activesupport')
-rw-r--r-- | activesupport/lib/active_support/core_ext/string/unicode.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/activesupport/lib/active_support/core_ext/string/unicode.rb b/activesupport/lib/active_support/core_ext/string/unicode.rb index 1f50773505..ba16d4d866 100644 --- a/activesupport/lib/active_support/core_ext/string/unicode.rb +++ b/activesupport/lib/active_support/core_ext/string/unicode.rb @@ -4,10 +4,11 @@ module ActiveSupport #:nodoc: unless '1.9'.respond_to?(:force_encoding) # Define methods for handling unicode data. module Unicode - def self.included(base) + def self.append_features(base) if '1.8.7'.respond_to?(:chars) base.class_eval { remove_method :chars } end + super end # +chars+ is a Unicode safe proxy for string methods. It creates and returns an instance of the |