Corrected documentation, update_attributes with a bang.

This commit is contained in:
dblock 2014-06-19 07:29:51 -04:00
parent 63724217f2
commit 4eaedf54bb
2 changed files with 3 additions and 3 deletions

View File

@ -6,7 +6,7 @@
**Note:** This version introduces several backward incompatible API changes. See [UPGRADING](UPGRADING.md) for details.
* [#172](https://github.com/intridea/hashie/pull/172): Added Dash and Trash#update_attributes - [@gregory](https://github.com/gregory).
* [#172](https://github.com/intridea/hashie/pull/172): Added Dash and Trash#update_attributes! - [@gregory](https://github.com/gregory).
* [#169](https://github.com/intridea/hashie/pull/169): Hash#to_hash will also convert nested objects that implement to_hash - [@gregory](https://github.com/gregory).
* [#150](https://github.com/intridea/hashie/pull/159): Handle nil intermediate object on deep fetch - [@stephenaument](https://github.com/stephenaument).
* [#146](https://github.com/intridea/hashie/issues/146): Mash#respond_to? inconsistent with #method_missing and does not respond to #permitted? - [@dblock](https://github.com/dblock).

View File

@ -205,10 +205,10 @@ p.occupation # => 'Rubyist'
p.email # => 'abc@def.com'
p[:awesome] # => NoMethodError
p[:occupation] # => 'Rubyist'
p.update_attributes(name: 'Trudy', occupation: 'Evil')
p.update_attributes!(name: 'Trudy', occupation: 'Evil')
p.occupation # => 'Evil'
p.name # => 'Trudy'
p.update_attributes(occupation: nil)
p.update_attributes!(occupation: nil)
p.occupation # => 'Rubyist'
```