diff options
author | Louise Crow <louise.crow@gmail.com> | 2012-09-20 17:46:54 +0100 |
---|---|---|
committer | Louise Crow <louise.crow@gmail.com> | 2012-10-10 17:53:43 +0100 |
commit | e429c43b7dfbadcd1715e24ace832e05a0271a78 (patch) | |
tree | 088ac5e526c7c1ddc643d9f984d5be07f7ad315a | |
parent | 83ba03721adb4b2446d38aaef9d11522d3a880dc (diff) |
Set the default internal and external encodings.
-rw-r--r-- | config/environment.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/config/environment.rb b/config/environment.rb index 3348ef92a..4ae3f26d9 100644 --- a/config/environment.rb +++ b/config/environment.rb @@ -1,5 +1,9 @@ # Be sure to restart your web server when you modify this file. +# the default encoding for IO is utf-8, and we use utf-8 internally +if RUBY_VERSION.to_f >= 1.9 + Encoding.default_external = Encoding.default_internal = Encoding::UTF_8 +end # Uncomment below to force Rails into production mode when # you don't control web/app server and can't set it the proper way |