mirror of https://github.com/Shizmob/pydle.git
Don't reset attributes twice on disconnect.
This commit is contained in:
parent
65604e20da
commit
71b8870522
|
@ -324,8 +324,6 @@ class BasicClient:
|
||||||
self.join(channel)
|
self.join(channel)
|
||||||
|
|
||||||
def on_disconnect(self, expected):
|
def on_disconnect(self, expected):
|
||||||
self._reset_attributes()
|
|
||||||
|
|
||||||
if not expected:
|
if not expected:
|
||||||
# Unexpected disconnect. Reconnect?
|
# Unexpected disconnect. Reconnect?
|
||||||
if self.RECONNECT_ON_ERROR and (self.RECONNECT_MAX_ATTEMPTS is None or self._reconnect_attempts < self.RECONNECT_MAX_ATTEMPTS):
|
if self.RECONNECT_ON_ERROR and (self.RECONNECT_MAX_ATTEMPTS is None or self._reconnect_attempts < self.RECONNECT_MAX_ATTEMPTS):
|
||||||
|
|
Loading…
Reference in New Issue