Maintain consistency of internal changed attributes hash.

This makes sure that the `_attributes` hash used to determine current
attribute values (and dirty state) is always in sync with the record's
original values.