lib/semantic_logger/loggable.rb in semantic_logger-4.3.1 vs lib/semantic_logger/loggable.rb in semantic_logger-4.4.0
- old
+ new
@@ -80,10 +80,10 @@
# unless visibility = Utils.method_visibility(self, method_name)
# logger.warn("Unable to measure method: #{name}##{method_name} since it does not exist")
# return false
# end
- index = SemanticLogger.level_to_index(level)
+ index = Levels.index(level)
logger_measure_module.module_eval(<<~MEASURE_METHOD, __FILE__, __LINE__ + 1)
def #{method_name}(*args, &block)
if logger.send(:level_index) <= #{index}
logger.send(