-
Type: Task
-
Resolution: Done
-
Affects Version/s: None
-
Component/s: None
-
None
After calling #destroy on a record #new_record? returns true. This is invalid and causes problems, for example when using with rails' dom_id helper.
The correct behavior, according to https://github.com/rails/rails/blob/master/activerecord/lib/active_record/persistence.rb, should be:
record.destroy
record.destroyed? -> true
record.new_record? -> false
record.persisted? -> false