Don't use `continue` inside `finally`

This commit is contained in:
Lauri Võsandi 2021-05-06 11:18:57 +03:00
parent 2bbf64c6d7
commit 657ee3a38e
1 changed files with 49 additions and 49 deletions

View File

@ -145,7 +145,7 @@ def certidude_enroll(fork, no_wait, kerberos):
authority_path = clients.get(authority_name, "authority path")
except NoOptionError:
authority_path = "/etc/certidude/authority/%s/ca_cert.pem" % authority_name
finally:
if os.path.exists(authority_path):
click.echo("Found authority certificate in: %s" % authority_path)
with open(authority_path, "rb") as fh:
@ -178,7 +178,7 @@ def certidude_enroll(fork, no_wait, kerberos):
config_path = clients.get(authority_name, "config path")
except NoOptionError:
config_path = "/etc/certidude/authority/%s/config.json" % authority_name
finally:
if os.path.exists(config_path):
click.echo("Found config in: %s" % config_path)
with open(config_path) as fh: