clean gajim.groups when we rename a group. Fixes #1778

This commit is contained in:
Yann Leboulanger 2006-03-29 22:11:14 +00:00
parent 5ff9b0fcba
commit b963fd1b25
1 changed files with 3 additions and 0 deletions

View File

@ -2522,6 +2522,9 @@ _('If "%s" accepts this request you will know his or her status.') % jid)
self.add_contact_to_roster(contact.jid, account) self.add_contact_to_roster(contact.jid, account)
gajim.connections[account].update_contact(contact.jid, gajim.connections[account].update_contact(contact.jid,
contact.name, contact.groups) contact.name, contact.groups)
# If last removed iter was not visible, gajim.groups is not cleaned
if gajim.groups[account].has_key(old_name):
del gajim.groups[account][old_name]
def on_service_disco_menuitem_activate(self, widget, account): def on_service_disco_menuitem_activate(self, widget, account):
server_jid = gajim.config.get_per('accounts', account, 'hostname') server_jid = gajim.config.get_per('accounts', account, 'hostname')