Permalink
Browse files

Don't shadow outer local variable.

  • Loading branch information...
1 parent f1778eb commit c13b7c4a0f7ddbd11f7570338cbd669afdb5af13 @miloops miloops committed Feb 15, 2011
Showing with 2 additions and 2 deletions.
  1. +2 −2 activerecord/lib/active_record/associations/class_methods/join_dependency.rb
@@ -187,8 +187,8 @@ def construct(parent, associations, join_parts, row)
construct(parent, association, join_parts, row)
end
when Hash
- associations.sort_by { |k,_| k.to_s }.each do |name, assoc|
- association = construct(parent, name, join_parts, row)
+ associations.sort_by { |k,_| k.to_s }.each do |association_name, assoc|
+ association = construct(parent, association_name, join_parts, row)
construct(association, assoc, join_parts, row) if association
end
else

0 comments on commit c13b7c4

Please sign in to comment.