mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Fix failing test
b63701e
moved the assignment before the query, but we need to capture
our old id before assignment in case we are assigning the id.
This commit is contained in:
parent
b63701e272
commit
3b2ea8b683
1 changed files with 1 additions and 0 deletions
|
@ -479,6 +479,7 @@ module ActiveRecord
|
|||
verify_readonly_attribute(key.to_s)
|
||||
end
|
||||
|
||||
id_in_database = self.id_in_database
|
||||
attributes.each do |k, v|
|
||||
write_attribute_without_type_cast(k, v)
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue