This commit is contained in:
Steven Bazyl 2014-12-18 09:21:33 -08:00
commit 6a6f1fb165
1 changed files with 7 additions and 1 deletions

View File

@ -10,7 +10,13 @@ module Google
# #
class Railtie < Rails::Railtie class Railtie < Rails::Railtie
initializer 'google-api-client' do |app| initializer 'google-api-client' do |app|
Google::APIClient.logger = app.logger _logger = case
when app.respond_to?(:logger) then app.logger
when app.config.respond_to?(:logger) then app.config.logger
else Rails.logger
end
Google::APIClient.logger = _logger
end end
end end
end end