Fix logger, take #2
This commit is contained in:
parent
3eac086797
commit
dcd1eb916a
|
@ -10,13 +10,8 @@ module Google
|
||||||
#
|
#
|
||||||
class Railtie < Rails::Railtie
|
class Railtie < Rails::Railtie
|
||||||
initializer 'google-api-client' do |app|
|
initializer 'google-api-client' do |app|
|
||||||
_logger = case
|
logger = app.config.logger || Rails.logger
|
||||||
when app.respond_to?(:logger) then app.logger
|
Google::APIClient.logger = logger unless logger.nil?
|
||||||
when app.config.respond_to?(:logger) then app.config.logger
|
|
||||||
else Rails.logger
|
|
||||||
end
|
|
||||||
|
|
||||||
Google::APIClient.logger = _logger
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -19,7 +19,7 @@ module Google
|
||||||
MAJOR = 0
|
MAJOR = 0
|
||||||
MINOR = 8
|
MINOR = 8
|
||||||
TINY = 1
|
TINY = 1
|
||||||
PATCH = nil
|
PATCH = 1
|
||||||
STRING = [MAJOR, MINOR, TINY, PATCH].compact.join('.')
|
STRING = [MAJOR, MINOR, TINY, PATCH].compact.join('.')
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue