method
stale_target?
v4.1.8 -
Show latest stable
- Class:
ActiveRecord::Associations::Association
stale_target?()public
The target is stale if the target no longer points to the record(s) that the relevant foreign_key(s) refers to. If stale, the association accessor method on the owner will reload the target. It’s up to subclasses to implement the stale_state method if relevant.
Note that if the target has not been loaded, it is not considered stale.