From 794a6ca71ebdd3794710c503131580e9cb02982c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafael=20Mendon=C3=A7a=20Fran=C3=A7a?= Date: Mon, 27 Mar 2017 19:19:44 -0400 Subject: Apply the log_level default Since 4.2 the default log level in production is now debug. We removed the deprecation in c2e865849beadd99866e521a93d733da7d1b5255 but we don't reflected the default value. We are not appling it. Closes #28558 --- railties/lib/rails/application/configuration.rb | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'railties/lib/rails/application') diff --git a/railties/lib/rails/application/configuration.rb b/railties/lib/rails/application/configuration.rb index c3b91b8af9..7c49fabba5 100644 --- a/railties/lib/rails/application/configuration.rb +++ b/railties/lib/rails/application/configuration.rb @@ -14,9 +14,8 @@ module Rails :ssl_options, :public_file_server, :session_options, :time_zone, :reload_classes_only_on_change, :beginning_of_week, :filter_redirect, :x, :enable_dependency_loading, - :read_encrypted_secrets + :read_encrypted_secrets, :log_level - attr_writer :log_level attr_reader :encoding, :api_only def initialize(*) @@ -35,7 +34,7 @@ module Rails @session_store = nil @time_zone = "UTC" @beginning_of_week = :monday - @log_level = nil + @log_level = :debug @generators = app_generators @cache_store = [ :file_store, "#{root}/tmp/cache/" ] @railties_order = [:all] @@ -152,10 +151,6 @@ module Rails raise e, "Cannot load `Rails.application.database_configuration`:\n#{e.message}", e.backtrace end - def log_level - @log_level ||= (Rails.env.production? ? :info : :debug) - end - def colorize_logging ActiveSupport::LogSubscriber.colorize_logging end -- cgit v1.2.3