]> source.dussan.org Git - redmine.git/commitdiff
Compatibility with ruby1.8 (#19305).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Sun, 15 Mar 2015 19:56:54 +0000 (19:56 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Sun, 15 Mar 2015 19:56:54 +0000 (19:56 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@14115 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/models/setting.rb

index 2574649f31e95f62ec02bccf0fa7db0e9aa3d7be..0a40b183ed9081ab39ec97498c42ed04061afd21 100644 (file)
@@ -243,7 +243,7 @@ END_SRC
 private
 
   def force_utf8_strings(arg)
-    if arg.is_a?(String)
+    if arg.is_a?(String) && arg.respond_to?(:force_encoding)
       arg.dup.force_encoding('UTF-8')
     elsif arg.is_a?(Array)
       arg.map do |a|