home · contact · privacy
Server/py: Stricter command token counting.
authorChristian Heller <c.heller@plomlompom.de>
Tue, 24 Feb 2015 02:10:11 +0000 (03:10 +0100)
committerChristian Heller <c.heller@plomlompom.de>
Tue, 24 Feb 2015 02:10:11 +0000 (03:10 +0100)
plomrogue-server.py

index cae9d902fddcad86b0d0c5980c9e8622f9deb931..c28f4def769ed6b6518009c6d9c0e690daa12aae 100755 (executable)
@@ -69,7 +69,7 @@ def obey(command, prefix, replay=False, do_record=False):
         print("Can't tokenize command string: " + str(err) + ".")
         return
     if len(tokens) > 0 and tokens[0] in commands_db \
-       and len(tokens) >= commands_db[tokens[0]][0] + 1:
+       and len(tokens) == commands_db[tokens[0]][0] + 1:
         if commands_db[tokens[0]][1]:
             commands_db[tokens[0]][2]()
         elif replay: