instance method
previously_new_record?
Ruby on Rails 7.2.3
Since v6.1.7.10Signature
previously_new_record?()
Returns true if this object was just created – that is, prior to the last update or delete, the object didn’t exist in the database and new_record? would have returned true.
Source
# File activerecord/lib/active_record/persistence.rb, line 347
def previously_new_record?
@previously_new_record
end
Defined in activerecord/lib/active_record/persistence.rb line 347
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveRecord::Persistence