From 69f1a8e857877e85060bbd647853b431f9c3cba7 Mon Sep 17 00:00:00 2001 From: Tristan Debrunner Date: Thu, 1 Dec 2022 18:24:16 -0700 Subject: [PATCH] Fix panic when pressing cancel on list selector page --- refbox/src/app/mod.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/refbox/src/app/mod.rs b/refbox/src/app/mod.rs index b9625f61..46b623ad 100644 --- a/refbox/src/app/mod.rs +++ b/refbox/src/app/mod.rs @@ -1153,6 +1153,12 @@ impl Application for RefBoxApp { AppState::ParameterEditor(_, _) => ConfigPage::Tournament, AppState::KeypadPage(KeypadPage::GameNumber, _) => ConfigPage::Main, AppState::KeypadPage(KeypadPage::TeamTimeouts(_), _) => ConfigPage::Tournament, + AppState::ParameterList(param, _) => match param { + ListableParameter::Game => ConfigPage::Main, + ListableParameter::Tournament | ListableParameter::Pool => { + ConfigPage::Tournament + } + }, _ => unreachable!(), };