From 90ff5f1a74a8731fde4c6d915e79001addb9ef34 Mon Sep 17 00:00:00 2001 From: jsanders Date: Mon, 29 Aug 2011 16:10:45 -0600 Subject: Proposed fix for issue 79 - https://github.com/rails/arel/issues/79 - Pass the connection_pool to the ToSql initializer, rather than the engine itself. --- lib/arel/select_manager.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/arel/select_manager.rb') diff --git a/lib/arel/select_manager.rb b/lib/arel/select_manager.rb index 88f26e4894..7a1fbbe438 100644 --- a/lib/arel/select_manager.rb +++ b/lib/arel/select_manager.rb @@ -51,7 +51,7 @@ module Arel if $VERBOSE warn "(#{caller.first}) where_clauses is deprecated and will be removed in arel 3.0.0 with no replacement" end - to_sql = Visitors::ToSql.new @engine + to_sql = Visitors::ToSql.new @engine.connection_pool @ctx.wheres.map { |c| to_sql.accept c } end -- cgit v1.2.3