3
0
mirror of https://github.com/jlu5/PyLink.git synced 2024-11-01 01:09:22 +01:00

IRCNetwork: avoid sending multiple disconnect hooks for one disconnection

This commit is contained in:
James Lu 2017-12-03 17:46:24 -08:00
parent 8b62d6d458
commit bebdf2e4ff

View File

@ -1419,7 +1419,9 @@ class IRCNetwork(PyLinkNetworkCoreWithUtils):
except (OSError, RuntimeError, SystemExit) as e: except (OSError, RuntimeError, SystemExit) as e:
self._log_connection_error('(%s) Disconnected from IRC:', self.name, exc_info=True) self._log_connection_error('(%s) Disconnected from IRC:', self.name, exc_info=True)
if not self._aborted.is_set():
self.disconnect() self.disconnect()
if not self._run_autoconnect(): if not self._run_autoconnect():
return return