module Deimos::PhobosConfig

Module to handle phobos.yml as well as outputting the configuration to save to Phobos itself.

Public Instance Methods

to_h() click to toggle source

@return [Hash]

# File lib/deimos/config/phobos_config.rb, line 12
def to_h
  (FIELDS + [:handler]).map { |f|
    val = self.send(f)
    if f == :backoff && val
      [:backoff, _backoff(val)]
    elsif val.present?
      [f, val]
    end
  }.to_h
end