aboutsummaryrefslogtreecommitdiffstats
path: root/guides
diff options
context:
space:
mode:
authorEdouard CHIN <edouard.chin@shopify.com>2018-10-01 18:00:18 -0400
committerEdouard CHIN <edouard.chin@shopify.com>2018-10-02 12:59:04 -0400
commit783f86822b49aa39d122f9c86939a17dac869cad (patch)
tree2278ea2002e443b53103a10c3baeea50eacab580 /guides
parentcf608ee34dd833b0357ef4eefa692db33242d2aa (diff)
downloadrails-783f86822b49aa39d122f9c86939a17dac869cad.tar.gz
rails-783f86822b49aa39d122f9c86939a17dac869cad.tar.bz2
rails-783f86822b49aa39d122f9c86939a17dac869cad.zip
Deprecate the `LoggerSilence` constant:
- I found this weird that the LoggerSilence wasn't using the `ActiveSupport` namespace (AFAIK all other classes have it). This PR deprecate the use of `LoggerSilence` for `ActiveSupport::LoggerSilence` instead.
Diffstat (limited to 'guides')
-rw-r--r--guides/source/configuring.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/guides/source/configuring.md b/guides/source/configuring.md
index 18a377a02e..d23af2ca57 100644
--- a/guides/source/configuring.md
+++ b/guides/source/configuring.md
@@ -119,12 +119,12 @@ defaults to `:debug` for all environments. The available log levels are: `:debug
* `config.logger` is the logger that will be used for `Rails.logger` and any related Rails logging such as `ActiveRecord::Base.logger`. It defaults to an instance of `ActiveSupport::TaggedLogging` that wraps an instance of `ActiveSupport::Logger` which outputs a log to the `log/` directory. You can supply a custom logger, to get full compatibility you must follow these guidelines:
* To support a formatter, you must manually assign a formatter from the `config.log_formatter` value to the logger.
* To support tagged logs, the log instance must be wrapped with `ActiveSupport::TaggedLogging`.
- * To support silencing, the logger must include `LoggerSilence` and `ActiveSupport::LoggerThreadSafeLevel` modules. The `ActiveSupport::Logger` class already includes these modules.
+ * To support silencing, the logger must include `ActiveSupport::LoggerSilence` and `ActiveSupport::LoggerThreadSafeLevel` modules. The `ActiveSupport::Logger` class already includes these modules.
```ruby
class MyLogger < ::Logger
include ActiveSupport::LoggerThreadSafeLevel
- include LoggerSilence
+ include ActiveSupport::LoggerSilence
end
mylogger = MyLogger.new(STDOUT)