method
first_or_last
v3.2.13 -
Show latest stable
- Class:
ActiveRecord::Associations::CollectionAssociation
first_or_last(type, *args)private
Fetches the first/last using SQL if possible, otherwise from the target array.
first_or_last(type, *args)Fetches the first/last using SQL if possible, otherwise from the target array.