Don't add cert expiration timer if no certs are being used.
This commit is contained in:
parent
61a4f76c8d
commit
98677fd602
1 changed files with 3 additions and 0 deletions
|
@ -816,6 +816,9 @@ class XMLStream(object):
|
|||
def _cert_expiration(self, event):
|
||||
"""Schedule an event for when the TLS certificate expires."""
|
||||
|
||||
if not self.use_tls and not self.use_ssl:
|
||||
return
|
||||
|
||||
def restart():
|
||||
log.warn("The server certificate has expired. Restarting.")
|
||||
self.reconnect()
|
||||
|
|
Loading…
Reference in a new issue