xep-0054: XMPP clients should not reply to vcard "get" requests

This commit is contained in:
mathieui 2018-08-07 21:30:13 +02:00
parent 0f690d4005
commit a9abed6151
No known key found for this signature in database
GPG key ID: C59F84CEEFD616E3

View file

@ -123,7 +123,7 @@ class XEP_0054(BasePlugin):
if iq['type'] == 'result':
self.api['set_vcard'](jid=iq['from'], args=iq['vcard_temp'])
return
elif iq['type'] == 'get':
elif iq['type'] == 'get' and self.xmpp.is_component:
vcard = self.api['get_vcard'](iq['from'].bare)
if isinstance(vcard, Iq):
vcard.send()