Fix no section error when configuring app
This commit is contained in:
parent
1d9f507956
commit
09ccd3ba95
1 changed files with 2 additions and 0 deletions
|
@ -24,6 +24,8 @@ class Configs:
|
|||
return value
|
||||
|
||||
def set(self, name, value):
|
||||
if not self._config_parser.has_section(self._section_name):
|
||||
self._config_parser.add_section(self._section_name)
|
||||
self._config_parser.set(self._section_name, name, str(value))
|
||||
|
||||
def write(self):
|
||||
|
|
Loading…
Reference in a new issue