lib/user_preferences/preference.rb in user_preferences-1.0.0 vs lib/user_preferences/preference.rb in user_preferences-1.0.1
- old
+ new
@@ -6,10 +6,10 @@
validates :value, inclusion: { in: ->(p) { p.permitted_values }}
delegate :binary?, :default, :permitted_values, :lookup, :to_db, to: :definition
def update_value!(v)
- update_attributes!(value: v)
+ update!(value: v)
end
def value
lookup(attributes['value'])
end