Call to_sql method on ActiveRecord::Relation instance not it's relation

attribute.'
This commit is contained in:
Emilio Tagua
2009-08-18 19:38:03 -03:00
parent 74ed123e08
commit 0abba2813b

View File

@@ -1733,7 +1733,7 @@ module ActiveRecord #:nodoc:
end
def construct_finder_sql(options, scope = scope(:find))
construct_finder_arel(options, scope).relation.to_sql
construct_finder_arel(options, scope).to_sql
end
def construct_join(joins, scope)