mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
relation .present? and .blank? should not query SELECT COUNT(DISTINCT id)
This commit is contained in:
parent
e2b6751312
commit
9d52b45a5b
1 changed files with 4 additions and 0 deletions
|
@ -507,6 +507,10 @@ module ActiveRecord
|
|||
end
|
||||
end
|
||||
|
||||
def blank?
|
||||
to_a.blank?
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def references_eager_loaded_tables?
|
||||
|
|
Loading…
Reference in a new issue