]> source.dussan.org Git - redmine.git/commitdiff
Fixed a nil method error in Setting#value=
authorEric Davis <edavis@littlestreamsoftware.com>
Fri, 12 Feb 2010 22:08:02 +0000 (22:08 +0000)
committerEric Davis <edavis@littlestreamsoftware.com>
Fri, 12 Feb 2010 22:08:02 +0000 (22:08 +0000)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3417 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/models/setting.rb

index 16f59be7256563a98cd79b9b6e3cfd0bf6458ccd..70d8f2be16e79265f48fd1f97f9c610b80f48e88 100644 (file)
@@ -97,7 +97,7 @@ class Setting < ActiveRecord::Base
   end
   
   def value=(v)
-    v = v.to_yaml if v && @@available_settings[name]['serialized']
+    v = v.to_yaml if v && @@available_settings[name] && @@available_settings[name]['serialized']
     write_attribute(:value, v.to_s)
   end