This commit is contained in:
deathbybandaid 2022-02-23 12:24:52 -05:00
parent 54d165ae4e
commit f9ae21dd39
2 changed files with 3 additions and 3 deletions

View File

@ -34,7 +34,7 @@ def prerun(rulematch=False):
# This is where we rebuild trigger
# we validate a few things here
trigger = validate_trigger(trigger, commands[0])
trigger = validate_trigger(bot, trigger, commands[0])
# Get list of trigger command(s) by | split
commands = sb.commands.get_commands_split(trigger, "|")

View File

@ -4,7 +4,7 @@ import sopel
from sopel_SpiceBot_Core_1 import sb
def validate_trigger(trigger, trigger_dict):
def validate_trigger(bot, trigger, trigger_dict):
print(trigger.group(0))
print(trigger.group(1))
@ -17,7 +17,7 @@ def validate_trigger(trigger, trigger_dict):
elif trigger_dict["trigger_type"] == "action_command":
pretrigger = sb.commands.generate_pretrigger_action_command(trigger_dict)
matches = sopel.rules.get_triggered_rules(sopel, pretrigger)
matches = sopel.rules.get_triggered_rules(bot, pretrigger)
print(matches)
return trigger