summaryrefslogtreecommitdiff
path: root/src/roster.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/roster.py')
-rw-r--r--src/roster.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/roster.py b/src/roster.py
index 269c318f..957ed51a 100644
--- a/src/roster.py
+++ b/src/roster.py
@@ -55,7 +55,6 @@ class Roster(object):
key = JID(key).bare
if key in self.contacts and self.contacts[key] is not None:
return self.contacts[key]
- log.debug('JIDS: %s' % self.jids())
if key in self.jids():
contact = Contact(self.__node[key])
self.contacts[key] = contact
@@ -68,9 +67,9 @@ class Roster(object):
def __delitem__(self, jid):
"""Remove a contact from the roster"""
jid = JID(jid).bare
- if jid not in self.contacts:
- return log.debug('not in self.contacts')
contact = self[jid]
+ if not contact:
+ return
for group in list(self.groups.values()):
group.remove(contact)
if not group:
@@ -104,7 +103,6 @@ class Roster(object):
def jids(self):
"""List of the contact JIDS"""
- log.debug('%s' % self.__node.keys())
return [key for key in self.__node.keys() if key not in self.__mucs and key != self.jid]
def get_contacts(self):