From c6978c15e004ee87abd8b745082e0db02b908ed8 Mon Sep 17 00:00:00 2001 From: Yann Leboulanger Date: Tue, 3 Jan 2006 15:18:30 +0000 Subject: [PATCH] fix logic --- src/roster_window.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/roster_window.py b/src/roster_window.py index 807724660..23e338584 100644 --- a/src/roster_window.py +++ b/src/roster_window.py @@ -705,10 +705,15 @@ class RosterWindow: contact.status = status if show in ('offline', 'error') and \ not gajim.awaiting_events[account].has_key(contact.jid): - if len(contact_instances) > 1 or not showOffline: - # if multiple resources or we don't show offline contacts + if len(contact_instances) > 1: + # if multiple resources gajim.contacts.remove_contact(account, contact) - self.draw_contact(contact.jid, account) + self.draw_contact(contact.jid, account) + elif not showOffline: + # we don't show offline contacts + self.remove_contact(contact, account) + else: + self.draw_contact(contact.jid, account) else: if not self.get_contact_iter(contact.jid, account): self.add_contact_to_roster(contact.jid, account)