Module: Safubot::Log

Defined in:
lib/safubot/log.rb

Overview

Log is a simple wrapper for stdout and file-writing Logger instances.

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.pathObject

Returns the value of attribute path.



7
8
9
# File 'lib/safubot/log.rb', line 7

def path
  @path
end

Class Method Details

.method_missing(method, *args) ⇒ Object

Dispatch method calls to Logger objects.



16
17
18
19
20
# File 'lib/safubot/log.rb', line 16

def method_missing(method, *args)
  @stdlog ||= Logger.new(STDOUT)
  @stdlog.send(method, *args)
  @filelog.send(method, *args) if @filelog
end