From 4ce8d6b461d6e4ef523fe393aaf266e5c0d468b3 Mon Sep 17 00:00:00 2001 From: jesopo Date: Wed, 22 May 2019 11:56:21 +0100 Subject: [PATCH] Pass `server` through FAIL events, use FAIL `command` as part of event path --- modules/line_handler/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/line_handler/__init__.py b/modules/line_handler/__init__.py index 43cdc4bf..a11fdec5 100644 --- a/modules/line_handler/__init__.py +++ b/modules/line_handler/__init__.py @@ -55,8 +55,8 @@ class Module(ModuleManager.BaseModule): self.log.warn("FAIL (%s %s) received: %s", [command, error_code, description]) - self.events.on("received.fail").call(command=command, - error_code=error_code, context=context, description=description) + self.events.on("received.fail").on(command).call(error_code=error_code, + context=context, description=description, server=event["server"]) # first numeric line the server sends @utils.hook("raw.received.001", default_event=True)