Bladeren bron

lowercase command name

tags/v0.1
Ben Kurtovic 13 jaren geleden
bovenliggende
commit
ddc9d9bf26
2 gewijzigde bestanden met toevoegingen van 2 en 1 verwijderingen
  1. +1
    -1
      irc/commands/help.py
  2. +1
    -0
      irc/data.py

+ 1
- 1
irc/commands/help.py Bestand weergeven

@@ -41,7 +41,7 @@ class Help(BaseCommand):
commands = command_handler.get_commands()

dummy = Data() # dummy message to test which command classes pick up this command
dummy.command = command
dummy.command = command.lower() # lowercase command name
dummy.is_command = True

for cmnd in commands:


+ 1
- 0
irc/data.py Bestand weergeven

@@ -29,5 +29,6 @@ class Data(object):
if self.command.startswith('!') or self.command.startswith('.'):
self.is_command = True
self.command = self.command[1:] # strip '!' or '.'
self.command = self.command.lower() # lowercase command name
except AttributeError:
pass

Laden…
Annuleren
Opslaan