Skip to main content

MustRegisterSubsection

Registers a new subsection with the given name and configuration, returning the registered section. This function will panic if the registration fails.

def MustRegisterSubsection(
name: string,
cfg: config.Config
) - > config.Section

Registers a new configuration subsection with the given name and configuration. This function will panic if the registration fails.

Parameters​

NameTypeDescription
namestringThe unique name for the subsection to be registered.
cfgconfig.ConfigThe configuration object to associate with the new subsection.

Returns​

TypeDescription
config.SectionThe newly registered configuration section.