Fix bug with default response to Y/N prompts.

This commit is contained in:
Solderpunk 2023-11-26 12:12:19 +01:00
parent 0e91b4f894
commit e96d373eec
1 changed files with 1 additions and 1 deletions

View File

@ -13,7 +13,7 @@ def ask_yes_no(prompt, default=None):
while True:
resp = input(prompt)
if not resp.strip() and default != None:
return efault
return default
elif resp.strip().lower() in ("y", "yes"):
return True
elif resp.strip().lower() in ("n","no"):