Permalink
Browse files

pass the join type to the join_constraints method

  • Loading branch information...
tenderlove committed Oct 20, 2013
1 parent 2549f6d commit bae5e02cf33311318be9c7272852bbaef976bd7e
@@ -165,7 +165,8 @@ def instantiate(result_set, aliases)
def make_joins(node)
node.children.flat_map { |child|
- child.join_constraints(node, child.tables, child.reflection.chain)
+ chain = child.reflection.chain
+ child.join_constraints(node, child.join_type, child.tables, chain)
.concat make_joins(child)
}
end
@@ -25,7 +25,7 @@ def match?(other)
super && reflection == other.reflection
end
- def join_constraints(parent, tables, chain)
+ def join_constraints(parent, join_type, tables, chain)
joins = []
tables = tables.reverse

0 comments on commit bae5e02

Please sign in to comment.