summaryrefslogtreecommitdiff
path: root/sleekxmpp/clientxmpp.py
diff options
context:
space:
mode:
authorNathan Fritz <fritzy@netflint.net>2011-08-12 16:35:15 -0700
committerNathan Fritz <fritzy@netflint.net>2011-08-12 16:35:15 -0700
commitbd8c110f00a41917839a0578de68b80c39ee6e16 (patch)
treecc44410ba6e6efe7cfcf1decc8f1b1d8b2692aa7 /sleekxmpp/clientxmpp.py
parent0050c5112428939346397a4d2edfeb313c0fd497 (diff)
parentd7fe724145c2e01d1028dab773fb49414c6856dd (diff)
downloadslixmpp-bd8c110f00a41917839a0578de68b80c39ee6e16.tar.gz
slixmpp-bd8c110f00a41917839a0578de68b80c39ee6e16.tar.bz2
slixmpp-bd8c110f00a41917839a0578de68b80c39ee6e16.tar.xz
slixmpp-bd8c110f00a41917839a0578de68b80c39ee6e16.zip
Merge branch 'exceptions' into develop
Diffstat (limited to 'sleekxmpp/clientxmpp.py')
-rw-r--r--sleekxmpp/clientxmpp.py11
1 files changed, 3 insertions, 8 deletions
diff --git a/sleekxmpp/clientxmpp.py b/sleekxmpp/clientxmpp.py
index ad127726..366066de 100644
--- a/sleekxmpp/clientxmpp.py
+++ b/sleekxmpp/clientxmpp.py
@@ -227,8 +227,8 @@ class ClientXMPP(BaseXMPP):
'subscription': subscription,
'groups': groups}}
response = iq.send(block, timeout, callback)
- if response in [False, None] or not isinstance(response, Iq):
- return response
+ if response is None:
+ return None
return response['type'] == 'result'
def del_roster_item(self, jid):
@@ -261,12 +261,7 @@ class ClientXMPP(BaseXMPP):
iq.enable('roster')
response = iq.send(block, timeout, callback)
- if response == False:
- self.event('roster_timeout')
-
- if response in [False, None] or not isinstance(response, Iq):
- return response
- else:
+ if callback is None:
return self._handle_roster(response, request=True)
def _handle_connected(self, event=None):