diff options
-rw-r--r-- | slixmpp/plugins/xep_0092/version.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/slixmpp/plugins/xep_0092/version.py b/slixmpp/plugins/xep_0092/version.py index 9dbdc4e6..68c6a326 100644 --- a/slixmpp/plugins/xep_0092/version.py +++ b/slixmpp/plugins/xep_0092/version.py @@ -15,6 +15,7 @@ from slixmpp.xmlstream.handler import Callback from slixmpp.xmlstream.matcher import StanzaPath from slixmpp.plugins import BasePlugin from slixmpp.plugins.xep_0092 import Version, stanza +from slixmpp import coroutine_wrapper log = logging.getLogger(__name__) @@ -70,7 +71,9 @@ class XEP_0092(BasePlugin): iq['software_version']['os'] = self.os iq.send() - def get_version(self, jid, ifrom=None, timeout=None, callback=None): + @coroutine_wrapper + def get_version(self, jid, ifrom=None, timeout=None, callback=None, + coroutine=False): """ Retrieve the software version of a remote agent. @@ -82,4 +85,4 @@ class XEP_0092(BasePlugin): iq['from'] = ifrom iq['type'] = 'get' iq['query'] = Version.namespace - return iq.send(timeout=timeout, callback=callback) + return iq.send(timeout=timeout, callback=callback, coroutine=coroutine) |