instance method
find_take
Ruby on Rails 4.0.13
Since v4.0.13Signature
find_take()
No documentation comment.
Source
# File activerecord/lib/active_record/relation/finder_methods.rb, line 312
def find_take
if loaded?
@records.first
else
@take ||= limit(1).to_a.first
end
end
Defined in activerecord/lib/active_record/relation/finder_methods.rb line 312
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveRecord::FinderMethods