From d41618b96e3f9163e20c1c076bc1af297c259113 Mon Sep 17 00:00:00 2001 From: AdamRaichu <91494019+AdamRaichu@users.noreply.github.com> Date: Wed, 6 Dec 2023 17:34:00 -0500 Subject: [PATCH] fix extra prompt showing at end of program --- demo.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/demo.py b/demo.py index ca48ad3..0b744bd 100644 --- a/demo.py +++ b/demo.py @@ -154,7 +154,8 @@ def fixup_handle(handle): current_participants = [] current_effect = None -while True: +hasQuit = False +while not hasQuit: msg = im.receive() if msg is not None: # print(f'[{msg.sender}] {msg.text}') @@ -185,6 +186,7 @@ while True: print('handle : set the current handle (for sending messages)') print('\\: escape commands (will be removed from message)') elif msg == 'quit' or msg == 'q': + hasQuit = True break elif msg == 'effect' or msg == 'e' or msg.startswith("effect ") or msg.startswith("e "): msg = msg.split(" ")