Fix Don't process vCard avatars for MUC occupants caused TypeError
This commit is contained in:
parent
7548f44047
commit
34cd20339c
@ -124,10 +124,12 @@ class XEP_0153(BasePlugin):
|
|||||||
log.debug('Could not retrieve vCard for %s' % jid)
|
log.debug('Could not retrieve vCard for %s' % jid)
|
||||||
|
|
||||||
def _recv_presence(self, pres):
|
def _recv_presence(self, pres):
|
||||||
|
try:
|
||||||
if pres['muc']['affiliation']:
|
if pres['muc']['affiliation']:
|
||||||
# Don't process vCard avatars for MUC occupants
|
# Don't process vCard avatars for MUC occupants
|
||||||
# since they all share the same bare JID.
|
# since they all share the same bare JID.
|
||||||
return
|
return
|
||||||
|
except: pass
|
||||||
|
|
||||||
if not pres.match('presence/vcard_temp_update'):
|
if not pres.match('presence/vcard_temp_update'):
|
||||||
self.api['set_hash'](pres['from'], args=None)
|
self.api['set_hash'](pres['from'], args=None)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user