add src/Config.py.__delitem__

This commit is contained in:
jesopo 2019-12-07 11:05:13 +00:00
parent a98dc6e0a6
commit e08bac9312

View file

@ -29,9 +29,11 @@ class Config(object):
return self._config[key]
def __setitem__(self, key: str, value: str):
self._config[key] = value
def get(self, key: str, default: typing.Any=None) -> typing.Any:
return self._config.get(key, default)
def __delitem__(self, key: str):
self._config.__delitem__(key)
def __contains__(self, key: str) -> bool:
return key in self._config
def get(self, key: str, default: typing.Any=None) -> typing.Any:
return self._config.get(key, default)