Method: Sohm::Model#update
- Defined in:
- lib/sohm.rb
#update(attributes) ⇒ Object
Update the model attributes and call save.
Example:
User[1].update(:name => "John")
# It's the same as:
u = User[1]
u.update_attributes(:name => "John")
u.save
1216 1217 1218 1219 |
# File 'lib/sohm.rb', line 1216 def update(attributes) update_attributes(attributes) save end |