primitivus: fixes contact group update
This commit is contained in:
parent
f0fa9b699d
commit
f3a0686176
1 changed files with 40 additions and 14 deletions
|
|
@ -76,6 +76,14 @@ class ContactList(wx.SimpleHtmlListBox, QuickContactList):
|
|||
self.replace(jid)
|
||||
|
||||
def replace(self, contact, groups=None, attributes=None):
|
||||
"""Add a contact to the list if doesn't exist, else update it.
|
||||
|
||||
@param jid (JID)
|
||||
@param groups (list): list of groups or None to ignore the groups membership.
|
||||
@param attributes (dict)
|
||||
|
||||
XXX: None value for 'groups' has a different meaning than [None] which is for the default group.
|
||||
"""
|
||||
debug(_("update %s") % contact)
|
||||
if not self.__find_idx(contact):
|
||||
self.add(contact, groups)
|
||||
|
|
|
|||
Loading…
Reference in a new issue