Sha256: 4c38dedceffa3baf4250413b34c11db25cd5fe526543c2819f5c4f1a4e68ffd5
Contents?: true
Size: 433 Bytes
Versions: 7
Compression:
Stored size: 433 Bytes
Contents
require 'logger' class UnitLogger def self.method_missing(meth, *args, &block) return Rails.logger.send(meth, *args, &block) if defined? Rails return unit.send(meth, *args, &block) end def self.unit return @logger unless @logger.nil? @logger = Logger.new(STDOUT) @logger.formatter = proc do |severity, datetime, progname, msg| msg end @logger.level = Logger::DEBUG @logger end end
Version data entries
7 entries across 7 versions & 1 rubygems