Method: MultiLogger.extract_options

Defined in:
lib/multi_logger.rb

.extract_options(name, options) ⇒ Object



48
49
50
51
52
53
54
55
56
57
58
59
# File 'lib/multi_logger.rb', line 48

def extract_options(name, options)
  path = get_path(name, options[:path])

  if options[:shift_age] && options[:shift_size]
    [path, options[:shift_age], options[:shift_size]]
  elsif options[:shift_age]
    # options[:shift_age] => 'daily', 'weekly'
    [path, options[:shift_age]]
  else
    [path]
  end
end