core: replaced calls to client.xmlstream.send by client.send which is the right method to use. client.xmlstream should not be used directly

This commit is contained in:
Goffi 2017-02-04 17:59:13 +01:00
commit 6467bdb3c3
14 changed files with 54 additions and 58 deletions

View file

@ -162,7 +162,7 @@ class AdHocCommand(XMPPHandler):
if payload is not None:
command_elt.addChild(payload)
self.client.xmlstream.send(result)
self.client.send(result)
if status in (XEP_0050.STATUS.COMPLETED, XEP_0050.STATUS.CANCELED):
del self.sessions[session_id]
@ -176,7 +176,7 @@ class AdHocCommand(XMPPHandler):
if cmd_condition:
error_elt = iq_elt.elements(None, "error").next()
error_elt.addElement(cmd_condition, NS_COMMANDS)
self.client.xmlstream.send(iq_elt)
self.client.send(iq_elt)
del self.sessions[session_id]
def onRequest(self, command_elt, requestor, action, session_id):