Fixed logic bug in prefixchar questions.

This commit is contained in:
Jeremy Fincher 2003-11-22 17:08:39 +00:00
parent e6ad1614f3
commit d618e9ec87

View File

@ -437,10 +437,14 @@ 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