Change the behaviour of send_response in module
This commit is contained in:
parent
283b0d006e
commit
59aff52ce1
@ -83,11 +83,10 @@ class ModuleContext:
|
|||||||
|
|
||||||
def send_response(server, res):
|
def send_response(server, res):
|
||||||
if server in context.servers:
|
if server in context.servers:
|
||||||
r = res.next_response()
|
if res.server is not None:
|
||||||
if r.server is not None:
|
return context.servers[res.server].send_response(res)
|
||||||
return context.servers[r.server].send_response(r)
|
|
||||||
else:
|
else:
|
||||||
return context.servers[server].send_response(r)
|
return context.servers[server].send_response(res)
|
||||||
else:
|
else:
|
||||||
module.logger.error("Try to send a message to the unknown server: %s", server)
|
module.logger.error("Try to send a message to the unknown server: %s", server)
|
||||||
return False
|
return False
|
||||||
|
Loading…
Reference in New Issue
Block a user