Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDidr <Didr@users.noreply.github.com>2021-12-07 14:54:59 +0100
committerGitHub <noreply@github.com>2021-12-07 14:54:59 +0100
commite344021b58ee1773bc367ee80e46acd89f6d0a4d (patch)
treeaa9e27d3a72dcf933339fafbd580aa1910f939de
parentb1b820f4cbf4c6a02a9c4638a1f1887d66dbde9c (diff)
Add handling of default options in multi-choice menus
In multiple choice menu: Return `self.default_option` instead of visible name if visible name contains " (default)".
-rw-r--r--archinstall/lib/menu.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/archinstall/lib/menu.py b/archinstall/lib/menu.py
index c3436803..6f1c2237 100644
--- a/archinstall/lib/menu.py
+++ b/archinstall/lib/menu.py
@@ -68,7 +68,7 @@ class Menu(TerminalMenu):
idx = self.show()
if idx is not None:
if isinstance(idx, (list, tuple)):
- return [self.menu_options[i] for i in idx]
+ return [self.default_option if ' (default)' in self.menu_options[i] else self.menu_options[i] for i in idx]
else:
selected = self.menu_options[idx]
if ' (default)' in selected and self.default_option: