hobo: create [options] section if necessary (#9696)
This commit is contained in:
parent
d95287c2fb
commit
ac5adb3648
|
@ -277,6 +277,9 @@ class CmdCheckHobos(Command):
|
|||
config.add_section('hobo')
|
||||
config.set('hobo', 'timestamp', self.all_services.get('timestamp'))
|
||||
|
||||
if not 'options' in config.sections():
|
||||
config.add_section('options')
|
||||
|
||||
variables = {}
|
||||
api_secrets = {}
|
||||
for service in self.all_services.get('services', []):
|
||||
|
@ -313,9 +316,6 @@ class CmdCheckHobos(Command):
|
|||
for key, value in api_secrets.items():
|
||||
config.set('api-secrets', key, value)
|
||||
|
||||
if 'options' not in config.sections():
|
||||
config.add_section('options')
|
||||
|
||||
# add known services
|
||||
for service in self.all_services.get('services', []):
|
||||
if service.get('service-id') == 'fargo':
|
||||
|
|
Loading…
Reference in New Issue