lib/onering/logger.rb in onering-client-0.4.1 vs lib/onering/logger.rb in onering-client-0.4.2
- old
+ new
@@ -1,7 +1,8 @@
require 'logger'
require 'rainbow'
+require 'onering/version'
module Onering
class Logger
def self.setup(options={})
outputfn = options[:destination]
@@ -55,11 +56,11 @@
options[:destination].puts(logline)
})
self.level = (options[:threshold] || :info)
- self.debug("onering-client v#{Onering::Client::VERSION} started")
- self.debug("Logger is initialized. Output is #{outputfn || 'stderr'}, threshold: #{options[:threshold]} or worse", "Onering::Logger")
+ self.debug("onering-client v#{Onering::Client::VERSION} started") if defined?(Onering::FULL_CLIENT)
+ self.debug("Logger is initialized. Output is #{outputfn || 'stderr'}, threshold: #{options[:threshold]} or worse", (options[:name] || "Onering::Logger"))
end
def self.logger()
return @_logger
\ No newline at end of file