Improved configuration
This commit is contained in:
parent
d4919e027c
commit
5be2e83798
@ -334,7 +334,7 @@ class Configuration(ConfigurationABC):
|
||||
self._print_error(__name__, f'Cannot load config file: {file}! -> {e}')
|
||||
return {}
|
||||
|
||||
def add_configuration(self, key_type: type, value: ConfigurationModelABC):
|
||||
def add_configuration(self, key_type: Union[str, type], value: ConfigurationModelABC):
|
||||
self._config[key_type] = value
|
||||
|
||||
def get_configuration(self, search_type: Union[str, Type[ConfigurationModelABC]]) -> Union[
|
||||
|
@ -72,7 +72,7 @@ class ConfigurationABC(ABC):
|
||||
pass
|
||||
|
||||
@abstractmethod
|
||||
def add_configuration(self, key_type: type, value: object):
|
||||
def add_configuration(self, key_type: Union[str, type], value: object):
|
||||
"""
|
||||
Add configuration object
|
||||
:param key_type:
|
||||
|
Loading…
Reference in New Issue
Block a user