From f6b3a0c6cffa5ebf10d20c20b5cadd575c91fe81 Mon Sep 17 00:00:00 2001 From: mathieui Date: Thu, 12 Feb 2015 12:17:01 +0100 Subject: Fix the uses of stanza.reply() This is relying on the stanzas being copied for each handler. We no longer do that for performance reasons, so instead of editing the copy in-place, stanza.reply() now returns a new stanza. --- slixmpp/plugins/xep_0050/adhoc.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'slixmpp/plugins/xep_0050/adhoc.py') diff --git a/slixmpp/plugins/xep_0050/adhoc.py b/slixmpp/plugins/xep_0050/adhoc.py index cb179a03..17c4f7d0 100644 --- a/slixmpp/plugins/xep_0050/adhoc.py +++ b/slixmpp/plugins/xep_0050/adhoc.py @@ -339,7 +339,7 @@ class XEP_0050(BasePlugin): for item in payload: register_stanza_plugin(Command, item.__class__, iterable=True) - iq.reply() + iq = iq.reply() iq['command']['node'] = session['node'] iq['command']['sessionid'] = session['id'] @@ -382,7 +382,7 @@ class XEP_0050(BasePlugin): if handler: handler(iq, session) del self.sessions[sessionid] - iq.reply() + iq = iq.reply() iq['command']['node'] = node iq['command']['sessionid'] = sessionid iq['command']['status'] = 'canceled' @@ -421,7 +421,7 @@ class XEP_0050(BasePlugin): del self.sessions[sessionid] - iq.reply() + iq = iq.reply() iq['command']['node'] = node iq['command']['sessionid'] = sessionid iq['command']['actions'] = [] -- cgit v1.2.3