fix response string detection

This commit is contained in:
Tomáš Mládek 2019-10-22 20:23:15 +02:00
parent 0f8277f695
commit 7295306107

View file

@ -61,7 +61,7 @@ class DudleBot:
update.message.reply_text("No plan created yet! (Speak /newplan to do so.)") update.message.reply_text("No plan created yet! (Speak /newplan to do so.)")
return return
responses_str = update.message.text[len("/plan"):] responses_str = " ".join(update.message.text.split(" ")[1:])
responses_str = re.sub(r'[^A-Za-z?]', '', responses_str) responses_str = re.sub(r'[^A-Za-z?]', '', responses_str)
responses_str = [char.upper() for char in responses_str] responses_str = [char.upper() for char in responses_str]