mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-23 11:09:23 +01:00
Fixed logic bug in prefixchar questions.
This commit is contained in:
parent
e6ad1614f3
commit
d618e9ec87
@ -437,16 +437,20 @@ def main():
|
|||||||
partial to @, but that's because I've been using it since my ocamlbot
|
partial to @, but that's because I've been using it since my ocamlbot
|
||||||
days.""")
|
days.""")
|
||||||
import callbacks
|
import callbacks
|
||||||
|
invalidPrefixChar = False
|
||||||
conf.prefixChars = anything('What would you like your bot\'s '
|
conf.prefixChars = anything('What would you like your bot\'s '
|
||||||
'prefix character(s) to be?')
|
'prefix character(s) to be?')
|
||||||
|
for c in conf.prefixChars:
|
||||||
|
if c not in conf.validPrefixChars:
|
||||||
invalidPrefixChar = True
|
invalidPrefixChar = True
|
||||||
while invalidPrefixChar:
|
while invalidPrefixChar:
|
||||||
|
invalidPrefixChar = False
|
||||||
for c in conf.prefixChars:
|
for c in conf.prefixChars:
|
||||||
if c not in conf.validPrefixChars:
|
if c not in conf.validPrefixChars:
|
||||||
invalidPrefixChar = True
|
invalidPrefixChar = True
|
||||||
myPrint('%r is not a valid prefixChar.' % c)
|
myPrint('%r is not a valid prefixChar.' % c)
|
||||||
conf.prefixChars = anything('That includes one or more invalid '
|
conf.prefixChars = anything('That includes one or more invalid '
|
||||||
'prefix characters. What would you'
|
'prefix characters. What would you '
|
||||||
'like your bot\'s prefix character(s)'
|
'like your bot\'s prefix character(s)'
|
||||||
'to be?')
|
'to be?')
|
||||||
configVariables['prefixChars'] = conf.prefixChars
|
configVariables['prefixChars'] = conf.prefixChars
|
||||||
|
Loading…
Reference in New Issue
Block a user