Skip to content

Commit 7ac285f

Browse files
Merge branch 's-t-e-v-e-n-k-support-click-8.2' into issues2223
2 parents a8de9e6 + 590a528 commit 7ac285f

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

SoftLayer/CLI/formatting.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,10 @@ def confirm(prompt_str, default=False):
243243
default_str = 'n'
244244
prompt = '%s [y/N]' % prompt_str
245245

246-
ans = click.prompt(prompt, default=default_str, show_default=False)
246+
try:
247+
ans = click.prompt(prompt, default=default_str, show_default=False)
248+
except click.exceptions.Abort:
249+
return False
247250
if ans.lower() in ('y', 'yes', 'yeah', 'yup', 'yolo'):
248251
return True
249252

0 commit comments

Comments
 (0)