Class: Fixably::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/fixably/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#api_keyObject

Returns the value of attribute api_key.



7
8
9
# File 'lib/fixably/config.rb', line 7

def api_key
  @api_key
end

#subdomainObject

Returns the value of attribute subdomain.



8
9
10
# File 'lib/fixably/config.rb', line 8

def subdomain
  @subdomain
end

Instance Method Details

#loggerObject



10
11
12
# File 'lib/fixably/config.rb', line 10

def logger
  Logger.logger
end

#logger=(log) ⇒ Object



14
15
16
# File 'lib/fixably/config.rb', line 14

def logger=(log)
  Logger.logger = log
end

#require(param) ⇒ Object



18
19
20
21
22
23
# File 'lib/fixably/config.rb', line 18

def require(param)
  value = public_send(param)
  return value unless value.nil? || value.empty?

  require_error(param)
end