diff options
author | Daniel Schierbeck <daniel.schierbeck@gmail.com> | 2008-09-14 22:05:16 +0200 |
---|---|---|
committer | Daniel Schierbeck <daniel.schierbeck@gmail.com> | 2008-09-14 22:05:16 +0200 |
commit | 93a49c33cc0d35b7ee6ed2e0ff7caadd5a3e2e0f (patch) | |
tree | ddf015209c224082e33729ffd6660cd375870528 | |
parent | 4a9ddde0d349446c10c8d52c27972e2c377308ea (diff) | |
download | rails-93a49c33cc0d35b7ee6ed2e0ff7caadd5a3e2e0f.tar.gz rails-93a49c33cc0d35b7ee6ed2e0ff7caadd5a3e2e0f.tar.bz2 rails-93a49c33cc0d35b7ee6ed2e0ff7caadd5a3e2e0f.zip |
Fixed typo in ActiveRecord aggregations documentation.
-rw-r--r-- | activerecord/lib/active_record/aggregations.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/aggregations.rb b/activerecord/lib/active_record/aggregations.rb index 9eee7f2d98..ce95e34ae8 100644 --- a/activerecord/lib/active_record/aggregations.rb +++ b/activerecord/lib/active_record/aggregations.rb @@ -75,7 +75,7 @@ module ActiveRecord # # customer.balance = Money.new(20) # sets the Money value object and the attribute # customer.balance # => Money value object - # customer.balance.exchanged_to("DKK") # => Money.new(120, "DKK") + # customer.balance.exchange_to("DKK") # => Money.new(120, "DKK") # customer.balance > Money.new(10) # => true # customer.balance == Money.new(20) # => true # customer.balance < Money.new(5) # => false @@ -99,7 +99,7 @@ module ActiveRecord # relational unique identifiers (such as primary keys). Normal ActiveRecord::Base classes are entity objects. # # It's also important to treat the value objects as immutable. Don't allow the Money object to have its amount changed after - # creation. Create a new Money object with the new value instead. This is exemplified by the Money#exchanged_to method that + # creation. Create a new Money object with the new value instead. This is exemplified by the Money#exchange_to method that # returns a new value object instead of changing its own values. Active Record won't persist value objects that have been # changed through means other than the writer method. # |