lib/memolog.rb in memolog-0.3.1 vs lib/memolog.rb in memolog-0.3.2
- old
+ new
@@ -14,14 +14,13 @@
require "memolog/sidekiq_middleware"
module Memolog
extend self
- attr_accessor :config, :logdevs
+ attr_accessor :config
@config = Memolog::Config.new
- @logdevs = []
def configure
yield(config) if block_given?
end
@@ -38,9 +37,13 @@
Thread.current[:memolog_uuid]
end
def logger
Thread.current[:memolog_logger] ||= Logger.new(nil, formatter: config.formatter)
+ end
+
+ def logdevs
+ Thread.current[:memolog_logdevs] ||= []
end
def run
Thread.current[:memolog_uuid] = config.uuid_callable.call