class Workers::LogProxy

Attributes

logger[RW]

Public Class Methods

new(logger) click to toggle source
# File lib/workers/log_proxy.rb, line 5
def initialize(logger)
  @logger = logger.is_a?(Workers::LogProxy) ? logger.logger : logger

  nil
end

Public Instance Methods

debug(msg) click to toggle source
# File lib/workers/log_proxy.rb, line 11
def debug(msg)
  @logger.debug(msg) if @logger

  nil
end
error(msg) click to toggle source
# File lib/workers/log_proxy.rb, line 29
def error(msg)
  @logger.error(msg) if @logger

  nil
end
info(msg) click to toggle source
# File lib/workers/log_proxy.rb, line 17
def info(msg)
  @logger.info(msg) if @logger

  nil
end
warn(msg) click to toggle source
# File lib/workers/log_proxy.rb, line 23
def warn(msg)
  @logger.warn(msg) if @logger

  nil
end