Skip to content

Commit 92566d8

Browse files
committed
GH-244 explicitly require Y/N for Command._ask
1 parent 682d0f8 commit 92566d8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/manage/commands.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -621,7 +621,7 @@ def _ask(self, fmt, *args, yn_text="Y/n", expect_char="y"):
621621
resp = input().casefold()
622622
except Exception:
623623
return False
624-
return not resp or resp.startswith(expect_char.casefold())
624+
return not resp or resp == expect_char.casefold()
625625

626626
def ask_yn(self, fmt, *args):
627627
"Returns True if the user selects 'yes' or confirmations are skipped."

0 commit comments

Comments
 (0)