From 57bcdbf639ed912a336d6a1ce91edd195d907f6b Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Wed, 23 Feb 2022 13:55:18 -0500 Subject: [PATCH] test --- sopel_SpiceBot_Core_1/SBCore/commands/__init__.py | 3 --- sopel_SpiceBot_Core_Prerun/__init__.py | 6 ++++-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/sopel_SpiceBot_Core_1/SBCore/commands/__init__.py b/sopel_SpiceBot_Core_1/SBCore/commands/__init__.py index 9bc4dc5..4a48231 100644 --- a/sopel_SpiceBot_Core_1/SBCore/commands/__init__.py +++ b/sopel_SpiceBot_Core_1/SBCore/commands/__init__.py @@ -105,9 +105,7 @@ class Commands(): def get_command_from_trigger(self, trigger): commstring = trigger.args[1] - print(commstring) if commstring.startswith(tuple(self.config.prefix_list)): - print(commstring[:1]) command = commstring[1:].split(" ")[0] elif commstring.startswith(self.bot.nick): command = " ".join(commstring.split(" ")[1:]).split(" ")[0] @@ -115,7 +113,6 @@ class Commands(): command = commstring.split(" ")[0] else: command = "" - print(command) return command def get_commands_split(self, trigger, splitkey): diff --git a/sopel_SpiceBot_Core_Prerun/__init__.py b/sopel_SpiceBot_Core_Prerun/__init__.py index c42c1b6..0dfdb7b 100644 --- a/sopel_SpiceBot_Core_Prerun/__init__.py +++ b/sopel_SpiceBot_Core_Prerun/__init__.py @@ -31,9 +31,11 @@ def prerun(rulematch=False): for trigger_dict in commands: sb.commands.dispatch(trigger_dict) return - elif sb.commands.get_command_from_trigger(trigger) != commands[0]["trigger_command"]: + + trigger_command = sb.commands.get_command_from_trigger(trigger) + if trigger_command != commands[0]["trigger_command"]: print("compare time") - print(trigger.args[1].split("&&")[0]) + print(trigger_command) print(commands[0]["trigger_command"]) # This is where we rebuild trigger