diff options
author | Sam Stephenson <sam@37signals.com> | 2006-01-20 22:04:07 +0000 |
---|---|---|
committer | Sam Stephenson <sam@37signals.com> | 2006-01-20 22:04:07 +0000 |
commit | 06dd1f2ca3398b978bb286688aa68acacd7dd712 (patch) | |
tree | 7b924286338cb81f252b448ec3851238fab9573e /actionpack/lib/action_controller/benchmarking.rb | |
parent | f9c13e6134bbc32dd826eec39fedba5de2514f88 (diff) | |
download | rails-06dd1f2ca3398b978bb286688aa68acacd7dd712.tar.gz rails-06dd1f2ca3398b978bb286688aa68acacd7dd712.tar.bz2 rails-06dd1f2ca3398b978bb286688aa68acacd7dd712.zip |
Add render :update for inline RJS
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3441 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/lib/action_controller/benchmarking.rb')
-rw-r--r-- | actionpack/lib/action_controller/benchmarking.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/actionpack/lib/action_controller/benchmarking.rb b/actionpack/lib/action_controller/benchmarking.rb index ceed88f2bf..eff4d97fae 100644 --- a/actionpack/lib/action_controller/benchmarking.rb +++ b/actionpack/lib/action_controller/benchmarking.rb @@ -43,14 +43,14 @@ module ActionController #:nodoc: end end - def render_with_benchmark(options = nil, deprecated_status = nil) + def render_with_benchmark(options = nil, deprecated_status = nil, &block) unless logger - render_without_benchmark(options, deprecated_status) + render_without_benchmark(options, deprecated_status, &block) else db_runtime = ActiveRecord::Base.connection.reset_runtime if Object.const_defined?("ActiveRecord") && ActiveRecord::Base.connected? render_output = nil - @rendering_runtime = Benchmark::measure{ render_output = render_without_benchmark(options, deprecated_status) }.real + @rendering_runtime = Benchmark::measure{ render_output = render_without_benchmark(options, deprecated_status, &block) }.real if Object.const_defined?("ActiveRecord") && ActiveRecord::Base.connected? @db_rt_before_render = db_runtime |