method
persisted?
v3.0.0 -
Show latest stable
- Class:
ActiveRecord::Persistence
persisted?()public
Returns if the record is persisted, i.e. it’s not a new record and it was not destroyed.
2Notes
Opposite of #new_record?
So that next time I look I find it.
Not quite opposite of new_record?
#new_record? will not check if the record has been destroyed