Sha256: beab16a917effba1097fad47f706ce485f57bd80dd2618f437dff7ca4a9c3f5e
Contents?: true
Size: 579 Bytes
Versions: 14
Compression:
Stored size: 579 Bytes
Contents
module Synchronisable module Helper # Provides logging helper methods. # Class or module that includes this one # should implement `logger` method. # # @api private module Logging protected %i(verbose colorize).each do |name| define_method("#{name}_logging?".to_sym) do Synchronisable.config.logging[name] end end def log_info(msg, color = :white, force = true) text = msg.colorize(color) if colorize_logging? logger.info(text) if force || verbose_logging? end end end end
Version data entries
14 entries across 14 versions & 1 rubygems