Skip to content

Commit

Permalink
fix-2740 - Handle empty iface selection (archlinux#2747)
Browse files Browse the repository at this point in the history
  • Loading branch information
svartkanin authored Nov 4, 2024
1 parent 6553967 commit 4a06131
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions archinstall/lib/interactions/network_menu.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,10 @@ def _select_iface(self, data: List[Nic]) -> Optional[str]:
all_ifaces = list_interfaces().values()
existing_ifaces = [d.iface for d in data]
available = set(all_ifaces) - set(existing_ifaces)

if not available:
return None

choice = Menu(str(_('Select interface to add')), list(available), skip=True).run()

if choice.type_ == MenuSelectionType.Skip:
Expand Down

0 comments on commit 4a06131

Please sign in to comment.