Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

logger.silence is deprecated #5188

Merged
merged 1 commit into from

2 participants

@jlxw

No description provided.

@jlxw

Getting lotsa deprecation warnings when using benchmark with :silence

DEPRECATION WARNING: silence is deprecated and will be removed from Rails 3.2. (called from realtime at /opt/ruby-enterprise-1.8.7-2011.03/lib/ruby/1.8/benchmark.rb:308)

@spastorino spastorino merged commit c6bd8a9 into rails:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Feb 27, 2012
  1. @jlxw

    logger.silence is deprecated

    jlxw authored
This page is out of date. Refresh to see the latest.
Showing with 1 addition and 1 deletion.
  1. +1 −1  activesupport/lib/active_support/benchmarkable.rb
View
2  activesupport/lib/active_support/benchmarkable.rb
@@ -35,7 +35,7 @@ def benchmark(message = "Benchmarking", options = {})
options[:level] ||= :info
result = nil
- ms = Benchmark.ms { result = options[:silence] ? logger.silence { yield } : yield }
+ ms = Benchmark.ms { result = options[:silence] ? silence { yield } : yield }
logger.send(options[:level], '%s (%.1fms)' % [ message, ms ])
result
else
Something went wrong with that request. Please try again.