Use get_info instead of get_items to get account features

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
Maxime “pep” Buquet 2019-08-23 22:36:43 +02:00
parent de585a23b2
commit 0b6ef3a860
Signed by: pep
GPG key ID: DEDA74AEECA9D0F2

View file

@ -236,8 +236,8 @@ class XEP_0384(BasePlugin):
bundle = self._omemo.public_bundle.serialize(self.omemo_backend)
jid = self.xmpp.boundjid
items = await self.xmpp['xep_0030'].get_items(jid)
publish_options = PUBLISH_OPTIONS_NODE in items['features']
disco = await self.xmpp['xep_0030'].get_info(jid.bare)
publish_options = PUBLISH_OPTIONS_NODE in disco['disco_info'].get_features()
iq = self.xmpp.Iq(stype='set')