From 6e3d2a7996f52bd0d7a5157f73a471307ba8aabd Mon Sep 17 00:00:00 2001 From: Jeremy Kemper Date: Thu, 21 Aug 2008 21:40:49 -0700 Subject: Revert "Performance: freeze cached rows instead of duping" This reverts commit cd8e653d5b18e6d3c3acc9930832f8e23945e392. --- activerecord/lib/active_record/base.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activerecord/lib/active_record/base.rb') diff --git a/activerecord/lib/active_record/base.rb b/activerecord/lib/active_record/base.rb index 15c6bc1b4a..0cce1e0157 100644 --- a/activerecord/lib/active_record/base.rb +++ b/activerecord/lib/active_record/base.rb @@ -612,7 +612,7 @@ module ActiveRecord #:nodoc: # Post.find_by_sql ["SELECT title FROM posts WHERE author = ? AND created > ?", author_id, start_date] # > [#"The Cheap Man Buys Twice"}>, ...] def find_by_sql(sql) - connection.select_all(sanitize_sql(sql), "#{name} Load").map { |record| instantiate(record) } + connection.select_all(sanitize_sql(sql), "#{name} Load").collect! { |record| instantiate(record) } end # Checks whether a record exists in the database that matches conditions given. These conditions -- cgit v1.2.3