From def4891008180074b0a14869a35d0e279a41f74d Mon Sep 17 00:00:00 2001 From: Giuseppe Guerra Date: Fri, 11 Aug 2017 01:36:25 +0200 Subject: [PATCH] Fix wrong commands being triggered if they have the same letters at the beginning --- objects/fokabot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/objects/fokabot.py b/objects/fokabot.py index faee27a..7b7dbc5 100644 --- a/objects/fokabot.py +++ b/objects/fokabot.py @@ -41,7 +41,7 @@ def fokabotResponse(fro, chan, message): """ for i in fokabotCommands.commands: # Loop though all commands - if message.strip().startswith(i["trigger"]): + if message.strip().startswith("{} ".format(i["trigger"])): # message has triggered a command # Make sure the user has right permissions