[utils] Also only allow two empty invalid inputs

This commit is contained in:
derrod 2021-12-30 17:11:52 +01:00
parent af08f5d11b
commit 8512a9a7a1

View file

@ -26,6 +26,9 @@ def get_int_choice(prompt, default=None, min_choice=None, max_choice=None, retur
if default is not None:
return default
else:
if return_on_invalid:
return None
return_on_invalid = True
continue
else:
if min_choice is not None and choice < min_choice: