Method: ActiveRecord::Relation#many?
- Defined in:
- lib/active_record/relation.rb
#many? ⇒ Boolean
Returns true if there is more than one record.
423 424 425 426 427 428 429 |
# File 'lib/active_record/relation.rb', line 423 def many? return false if @none return super if block_given? return records.many? if loaded? limited_count > 1 end |