Class: GovukJsonLogging::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/govuk_app_config/govuk_json_logging.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



7
8
9
# File 'lib/govuk_app_config/govuk_json_logging.rb', line 7

def initialize
  @custom_fields_block = proc {}
end

Instance Attribute Details

#custom_fields_blockObject (readonly)

Returns the value of attribute custom_fields_block.



11
12
13
# File 'lib/govuk_app_config/govuk_json_logging.rb', line 11

def custom_fields_block
  @custom_fields_block
end

Instance Method Details

#add_custom_fields(&block) ⇒ Object



13
14
15
# File 'lib/govuk_app_config/govuk_json_logging.rb', line 13

def add_custom_fields(&block)
  @custom_fields_block = block if block_given?
end