Module: Plug::Configuration

Included in:
Plug
Defined in:
lib/plug/configuration.rb

Constant Summary collapse

AUTH_USER =
''
AUTH_PASSWORD =
''
ALLOW_DELETE =
true
VALID_OPTIONS_KEYS =
%i[
  auth_user
  auth_password
  allow_delete
  buttons
  api_path
  themes
].freeze

Instance Method Summary collapse

Instance Method Details

#configure {|_self| ... } ⇒ Object

Yields:

  • (_self)

Yield Parameters:



20
21
22
# File 'lib/plug/configuration.rb', line 20

def configure
  yield self
end

#optionsObject



24
25
26
# File 'lib/plug/configuration.rb', line 24

def options
  Hash[* VALID_OPTIONS_KEYS.map { |key| [key, send(key)] }.flatten]
end