mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Fix the shadowing warning for reflection
This commit is contained in:
parent
2f9d88954c
commit
9b986eadf4
1 changed files with 2 additions and 2 deletions
|
@ -90,8 +90,8 @@ module ActiveRecord
|
|||
relation.preload! other.preload_values unless other.preload_values.empty?
|
||||
relation.includes! other.includes_values unless other.includes_values.empty?
|
||||
else
|
||||
reflection = relation.klass.reflect_on_all_associations.find do |reflection|
|
||||
reflection.class_name == other.klass.name
|
||||
reflection = relation.klass.reflect_on_all_associations.find do |r|
|
||||
r.class_name == other.klass.name
|
||||
end || return
|
||||
|
||||
unless other.preload_values.empty?
|
||||
|
|
Loading…
Reference in a new issue