From 0d7c1bfc2da60b13674990f881181a78cc068f5b Mon Sep 17 00:00:00 2001 From: Tamas Gal <tgal@km3net.de> Date: Fri, 4 Oct 2019 17:53:18 +0200 Subject: [PATCH] Allow operators to check status --- scripts/chatbot.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/chatbot.py b/scripts/chatbot.py index d1a139f..f247e69 100644 --- a/scripts/chatbot.py +++ b/scripts/chatbot.py @@ -74,10 +74,10 @@ def register_handlers(bot): if channel_id != CHANNEL_ID: print("skipping") return - if not is_shifter(user): + if not is_shifter(user) and not is_operator(): bot.send_message( - "Only shifters are allowed to mess with me, sorry...", - channel_id) + "Only operators and shifters are allowed to mess " + "with me, sorry...", channel_id) return status = subprocess.check_output(['supervisorctl', 'status']) bot.send_message(status, channel_id) -- GitLab