diff options
author | Florent Le Coz <louiz@louiz.org> | 2011-09-11 03:32:54 +0200 |
---|---|---|
committer | Florent Le Coz <louiz@louiz.org> | 2011-09-11 03:32:54 +0200 |
commit | 1a485318bfc1a3db4cd970785029eeb8b03bf0b3 (patch) | |
tree | 9319d8ac45ff027a21b85ec7e78a40687806d022 | |
parent | e84cbf6ba5b748881ea3f99471a39a8f1fde772a (diff) | |
download | poezio-1a485318bfc1a3db4cd970785029eeb8b03bf0b3.tar.gz poezio-1a485318bfc1a3db4cd970785029eeb8b03bf0b3.tar.bz2 poezio-1a485318bfc1a3db4cd970785029eeb8b03bf0b3.tar.xz poezio-1a485318bfc1a3db4cd970785029eeb8b03bf0b3.zip |
Fix a traceback when a contact not yet accepted goes offline
-rw-r--r-- | src/core.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/core.py b/src/core.py index 340cdf8a..4a2cc91f 100644 --- a/src/core.py +++ b/src/core.py @@ -337,7 +337,8 @@ class Core(object): return log.debug('on_got_offline: %s' % presence) resource = contact.get_resource_by_fulljid(jid.full) - assert resource + if not resource: + return # If a resource got offline, display the message in the conversation with this # precise resource. self.add_information_message_to_conversation_tab(jid.full, '\x195%s is \x191offline' % (resource.get_jid().full)) |