diff options
author | Jacob Evelyn <jevelyn@panoramaed.com> | 2014-06-02 16:13:41 -0400 |
---|---|---|
committer | Jacob Evelyn <jevelyn@panoramaed.com> | 2014-06-02 16:13:41 -0400 |
commit | 608683745fdd1286488417011db57f25d541226d (patch) | |
tree | c7563001c42cd32e30875d8991e0b134a3362a8c /activerecord/lib | |
parent | b5d53f864826c7ce88af0d8b9a9ff45f95956f6b (diff) | |
download | rails-608683745fdd1286488417011db57f25d541226d.tar.gz rails-608683745fdd1286488417011db57f25d541226d.tar.bz2 rails-608683745fdd1286488417011db57f25d541226d.zip |
Use logger environment settings in Rails console.
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/active_record/railtie.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/activerecord/lib/active_record/railtie.rb b/activerecord/lib/active_record/railtie.rb index a4ceacbf44..bd09bbc705 100644 --- a/activerecord/lib/active_record/railtie.rb +++ b/activerecord/lib/active_record/railtie.rb @@ -60,6 +60,9 @@ module ActiveRecord require "active_record/railties/console_sandbox" if app.sandbox? require "active_record/base" console = ActiveSupport::Logger.new(STDERR) + console.formatter = Rails.logger.formatter + console.level = Rails.logger.level + Rails.logger.extend ActiveSupport::Logger.broadcast console end |