From 304c49b1468ce71beb7e3ea0ca4c5add73a1534e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Valim?= Date: Sun, 25 Jul 2010 20:59:37 +0200 Subject: Move runtime back to connection. --- activerecord/lib/active_record/railties/controller_runtime.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'activerecord/lib/active_record/railties') diff --git a/activerecord/lib/active_record/railties/controller_runtime.rb b/activerecord/lib/active_record/railties/controller_runtime.rb index bc6ca936c0..aed1c59b00 100644 --- a/activerecord/lib/active_record/railties/controller_runtime.rb +++ b/activerecord/lib/active_record/railties/controller_runtime.rb @@ -11,9 +11,9 @@ module ActiveRecord def cleanup_view_runtime if ActiveRecord::Base.connected? - db_rt_before_render = ActiveRecord::LogSubscriber.reset_runtime + db_rt_before_render = ActiveRecord::Base.connection.reset_runtime runtime = super - db_rt_after_render = ActiveRecord::LogSubscriber.reset_runtime + db_rt_after_render = ActiveRecord::Base.connection.reset_runtime self.db_runtime = db_rt_before_render + db_rt_after_render runtime - db_rt_after_render else -- cgit v1.2.3