Print config parsing failures instead of sending them to the debug function

This commit is contained in:
Mark Veidemanis 2017-11-19 14:50:29 +00:00
parent 6adb59c170
commit 013b9b7cfe
1 changed files with 2 additions and 2 deletions

View File

@ -63,11 +63,11 @@ def getconfig():
if set(["port", "bind", "usessl"]).issubset(set(config.keys())):
if config["usessl"] == True:
if not set(["cert", "key"]).issubset(set(config.keys())):
debug("SSL is on but certificate or key is not defined")
print("SSL is on but certificate or key is not defined")
exit(1)
return config
else:
debug("Mandatory values missing from config")
print("Mandatory values missing from config")
exit(1)
if __name__ == "__main__":