summaryrefslogtreecommitdiff
path: root/slixmpp/clientxmpp.py
diff options
context:
space:
mode:
authorEmmanuel Gil Peyrot <linkmauve@linkmauve.fr>2018-07-01 18:46:33 +0200
committerEmmanuel Gil Peyrot <linkmauve@linkmauve.fr>2018-07-01 18:46:33 +0200
commit3502480384bd7d9f4e4eb1a3b92e8df08f4e487c (patch)
treea2e68835f4de6c32808412455f88310c05528191 /slixmpp/clientxmpp.py
parent66909aafb300868ffd3ed9ab02bc3bd28c49a6e9 (diff)
downloadslixmpp-3502480384bd7d9f4e4eb1a3b92e8df08f4e487c.tar.gz
slixmpp-3502480384bd7d9f4e4eb1a3b92e8df08f4e487c.tar.bz2
slixmpp-3502480384bd7d9f4e4eb1a3b92e8df08f4e487c.tar.xz
slixmpp-3502480384bd7d9f4e4eb1a3b92e8df08f4e487c.zip
Switch from @asyncio.coroutine to async def everywhere.
Diffstat (limited to 'slixmpp/clientxmpp.py')
-rw-r--r--slixmpp/clientxmpp.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/slixmpp/clientxmpp.py b/slixmpp/clientxmpp.py
index 891a9fb6..1bbf5216 100644
--- a/slixmpp/clientxmpp.py
+++ b/slixmpp/clientxmpp.py
@@ -265,8 +265,7 @@ class ClientXMPP(BaseXMPP):
self.bindfail = False
self.features = set()
- @asyncio.coroutine
- def _handle_stream_features(self, features):
+ async def _handle_stream_features(self, features):
"""Process the received stream features.
:param features: The features stanza.
@@ -275,7 +274,7 @@ class ClientXMPP(BaseXMPP):
if name in features['features']:
handler, restart = self._stream_feature_handlers[name]
if asyncio.iscoroutinefunction(handler):
- result = yield from handler(features)
+ result = await handler(features)
else:
result = handler(features)
if result and restart: