diff options
author | lovetox <philipp@hoerist.com> | 2022-08-08 00:59:26 +0300 |
---|---|---|
committer | lovetox <philipp@hoerist.com> | 2022-08-09 17:48:39 +0300 |
commit | 15121542093e7ee5b58e33dde81c18cd41f2589e (patch) | |
tree | 1051eb25af44ffef81337f3ff1e206acb0c32091 | |
parent | 9aa7d949c897d9ea747d9a9899f2c1cd015fa0b2 (diff) |
fix: Check for None
-rw-r--r-- | gajim/gtk/control.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gajim/gtk/control.py b/gajim/gtk/control.py index ea90befca..69284ff58 100644 --- a/gajim/gtk/control.py +++ b/gajim/gtk/control.py @@ -134,7 +134,9 @@ class ChatControl(EventHelper): return self.contact is not None def clear(self) -> None: - self.contact.disconnect_all_from_obj(self) + if self.contact is not None: + self.contact.disconnect_all_from_obj(self) + self.contact = None self._clinet = None self.account = None |