Open joeswann opened 10 years ago
replacing find_or_create_by_name_and_locale(name, (locale || I18n.locale)).value
with self.where(:name => name, :locale => (locale || I18n.locale)).first_or_initialize
Seems to do the trick
same problem on Rails 4.1.5
I installed the latest master (for Rails 4) and everything seems to be fine up until using settings_value in either the view or the controller.
I think this may be a deprecated function http://stackoverflow.com/questions/3046607/rails-find-or-create-by-more-than-one-attribute