1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2026-04-15 23:47:24 +02:00

Fixed RET505 (superfluous-else-return)

This commit is contained in:
Teal Dulcet
2025-06-18 04:19:55 -07:00
parent 3008dfa28f
commit dbabd69218
9 changed files with 72 additions and 89 deletions

View File

@@ -256,10 +256,9 @@ def get_web_domains_info(env):
cert_status, cert_status_details = check_certificate(domain, tls_cert["certificate"], tls_cert["private-key"])
if cert_status == "OK":
return ("success", "Signed & valid. " + cert_status_details)
elif cert_status == "SELF-SIGNED":
if cert_status == "SELF-SIGNED":
return ("warning", "Self-signed. Get a signed certificate to stop warnings.")
else:
return ("danger", "Certificate has a problem: " + cert_status)
return ("danger", "Certificate has a problem: " + cert_status)
return [
{