From 9efb0b05fcbb547b78928470a647b55c913d6b7a Mon Sep 17 00:00:00 2001 From: jesopo Date: Wed, 1 Jan 2020 10:04:32 +0000 Subject: by default, don't trigger command.regex events when in a statusmsg --- src/core_modules/commands/__init__.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/core_modules') diff --git a/src/core_modules/commands/__init__.py b/src/core_modules/commands/__init__.py index e330e2c6..9822903f 100644 --- a/src/core_modules/commands/__init__.py +++ b/src/core_modules/commands/__init__.py @@ -332,6 +332,9 @@ class Module(ModuleManager.BaseModule): for hook in regex_hooks: if event["action"] and hook.get_kwarg("ignore_action", True): continue + if event["statusmsg"] and not hook.get_kwarg("statusmsg", False + ): + continue pattern = hook.get_kwarg("pattern", None) if pattern: -- cgit v1.3.1-10-gc9f91