mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
In #apply_join_dependency, we can apply the #where in-place because relation is always a new object.
Thanks to the #except we call at the top of the method.
This commit is contained in:
parent
75fe7434a8
commit
35c198ca9b
1 changed files with 1 additions and 1 deletions
|
@ -233,7 +233,7 @@ module ActiveRecord
|
|||
if using_limitable_reflections?(join_dependency.reflections)
|
||||
relation
|
||||
else
|
||||
relation = relation.where(construct_limited_ids_condition(relation)) if relation.limit_value
|
||||
relation.where!(construct_limited_ids_condition(relation)) if relation.limit_value
|
||||
relation.except(:limit, :offset)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue