xmpppy doesn't raise exceptions!

This commit is contained in:
Tomasz Melcer 2007-06-28 08:14:25 +00:00
parent 976cd12eef
commit 4c1fdb1fd8
1 changed files with 3 additions and 4 deletions

View File

@ -225,15 +225,14 @@ class ConnectionCaps(object):
caps=presence.getTag('c') caps=presence.getTag('c')
if not caps: return if not caps: return
try:
node, ver=caps['node'], caps['ver'] node, ver=caps['node'], caps['ver']
except KeyError: if node is None or ver is None:
# improper caps in stanza, ignoring # improper caps in stanza, ignoring
return return
try: try:
exts=caps['ext'].split(' ') exts=caps['ext'].split(' ')
except KeyError: except AttributeError:
# no exts means no exts, a perfectly valid case # no exts means no exts, a perfectly valid case
exts=[] exts=[]