[3.12] gh-113113: doc: use less ambiguously named variable (gh-113114) (gh-113122)

This commit is contained in:
Miss Islington (bot) 2023-12-14 17:25:07 +01:00 committed by GitHub
parent c6c559a669
commit a157881dbc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -559,10 +559,10 @@ defined to allow. For example::
def ask_ok(prompt, retries=4, reminder='Please try again!'):
while True:
ok = input(prompt)
if ok in ('y', 'ye', 'yes'):
reply = input(prompt)
if reply in {'y', 'ye', 'yes'}:
return True
if ok in ('n', 'no', 'nop', 'nope'):
if reply in {'n', 'no', 'nop', 'nope'}:
return False
retries = retries - 1
if retries < 0: