From ab03ad54aaca1725b943abf16585fa4ef6f08897 Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Wed, 30 Jul 2014 17:52:59 +0200 Subject: Fix the iq.send() function, and a bunch of places where it is called This is a big-and-dirty commit with a bunch of cleanup, maybe breaking a few things, and not fixing all iq.send() calls yet. --- slixmpp/plugins/xep_0049/private_storage.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'slixmpp/plugins/xep_0049/private_storage.py') diff --git a/slixmpp/plugins/xep_0049/private_storage.py b/slixmpp/plugins/xep_0049/private_storage.py index 99a04fe9..a66c05d1 100644 --- a/slixmpp/plugins/xep_0049/private_storage.py +++ b/slixmpp/plugins/xep_0049/private_storage.py @@ -32,7 +32,8 @@ class XEP_0049(BasePlugin): def register(self, stanza): register_stanza_plugin(PrivateXML, stanza, iterable=True) - def store(self, data, ifrom=None, block=True, timeout=None, callback=None): + def store(self, data, ifrom=None, timeout=None, callback=None, + timeout_callback=None): iq = self.xmpp.Iq() iq['type'] = 'set' iq['from'] = ifrom @@ -43,11 +44,14 @@ class XEP_0049(BasePlugin): for elem in data: iq['private'].append(elem) - return iq.send(block=block, timeout=timeout, callback=callback) + return iq.send(timeout=timeout, callback=callback, + timeout_callback=timeout_callback) - def retrieve(self, name, ifrom=None, block=True, timeout=None, callback=None): + def retrieve(self, name, ifrom=None, timeout=None, callback=None, + timeout_callback=None): iq = self.xmpp.Iq() iq['type'] = 'get' iq['from'] = ifrom iq['private'].enable(name) - return iq.send(block=block, timeout=timeout, callback=callback) + return iq.send(timeout=timeout, callback=callback, + timeout_callback=timeout_callback) -- cgit v1.2.3