ui: guard branch switcher before internet connected (#38692)

This commit is contained in:
Trey Moen
2026-08-28 12:06:33 -07:00
committed by GitHub
parent 5645370f84
commit 839d3f5004
@@ -246,6 +246,9 @@ class TargetBranchButton(BigButton):
self.set_value(target)
def _on_click(self):
if not ui_state.params.get("UpdaterAvailableBranches"):
gui_app.push_widget(BigDialog("", tr("Please connect to Wi-Fi to switch branches.")))
return
gui_app.push_widget(BranchSelectPage(self._on_select))
def _on_select(self, branch: str):