method
cleanup_view_runtime
v3.1.0 -
Show latest stable
- Class:
ActiveRecord::Railties::ControllerRuntime
cleanup_view_runtime()protected
No documentation available.
# File activerecord/lib/active_record/railties/controller_runtime.rb, line 21
def cleanup_view_runtime
if ActiveRecord::Base.connected?
db_rt_before_render = ActiveRecord::LogSubscriber.reset_runtime
runtime = super
db_rt_after_render = ActiveRecord::LogSubscriber.reset_runtime
self.db_runtime = db_rt_before_render + db_rt_after_render
runtime - db_rt_after_render
else
super
end
end