aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
diff options
context:
space:
mode:
authorschneems <richard.schneeman@gmail.com>2014-05-11 12:55:05 -0500
committerschneems <richard.schneeman@gmail.com>2014-05-29 14:38:09 -0500
commitd7d7211c5344d5af9968abbb70e84fec64858781 (patch)
tree1709a5b1caa366afbcb8f5c102dc6efefc3fe7c3 /activerecord
parent9b6b32a76edafd0c19c14b61565e536e2238a068 (diff)
downloadrails-d7d7211c5344d5af9968abbb70e84fec64858781.tar.gz
rails-d7d7211c5344d5af9968abbb70e84fec64858781.tar.bz2
rails-d7d7211c5344d5af9968abbb70e84fec64858781.zip
[ci skip] add created_at and updated_at to example
Diffstat (limited to 'activerecord')
-rw-r--r--activerecord/lib/active_record/attribute_assignment.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/attribute_assignment.rb b/activerecord/lib/active_record/attribute_assignment.rb
index 87ecbe54f1..59614a67b1 100644
--- a/activerecord/lib/active_record/attribute_assignment.rb
+++ b/activerecord/lib/active_record/attribute_assignment.rb
@@ -13,9 +13,9 @@ module ActiveRecord
# exception is raised.
#
# cat = Cat.new(name: "Gorby", status: "yawning")
- # cat.attributes # => { "name" => "Gorby", "status" => "yawning" }
+ # cat.attributes # => { "name" => "Gorby", "status" => "yawning", "created_at" => nil, "updated_at" => nil}
# cat.assign_attributes(status: "sleeping")
- # cat.attributes # => { "name" => "Gorby", "status" => "sleeping" }
+ # cat.attributes # => { "name" => "Gorby", "status" => "sleeping", "created_at" => nil, "updated_at" => nil }
#
# New attributes will be persisted in the database when the object is saved.
#