don't remove metacontact when we reconnect. fixes #3771
This commit is contained in:
parent
c497087115
commit
f3665cd689
|
@ -216,13 +216,14 @@ class Contacts:
|
||||||
def clear_contacts(self, account):
|
def clear_contacts(self, account):
|
||||||
self._contacts[account] = {}
|
self._contacts[account] = {}
|
||||||
|
|
||||||
def remove_jid(self, account, jid):
|
def remove_jid(self, account, jid, remove_meta=True):
|
||||||
'''Removes all contacts for a given jid'''
|
'''Removes all contacts for a given jid'''
|
||||||
if not self._contacts.has_key(account):
|
if not self._contacts.has_key(account):
|
||||||
return
|
return
|
||||||
if not self._contacts[account].has_key(jid):
|
if not self._contacts[account].has_key(jid):
|
||||||
return
|
return
|
||||||
del self._contacts[account][jid]
|
del self._contacts[account][jid]
|
||||||
|
if remove_meta:
|
||||||
# remove metacontacts info
|
# remove metacontacts info
|
||||||
self.remove_metacontact(account, jid)
|
self.remove_metacontact(account, jid)
|
||||||
|
|
||||||
|
|
|
@ -1294,7 +1294,7 @@ class RosterWindow:
|
||||||
gajim.groups[account] = {}
|
gajim.groups[account] = {}
|
||||||
for jid in array.keys():
|
for jid in array.keys():
|
||||||
# Remove old Contact instances
|
# Remove old Contact instances
|
||||||
gajim.contacts.remove_jid(account, jid)
|
gajim.contacts.remove_jid(account, jid, remove_meta=False)
|
||||||
jids = jid.split('/')
|
jids = jid.split('/')
|
||||||
# get jid
|
# get jid
|
||||||
ji = jids[0]
|
ji = jids[0]
|
||||||
|
|
Loading…
Reference in New Issue