From 48e19c1f7f73ccf5d229cb85215897a1d23ee7e9 Mon Sep 17 00:00:00 2001 From: Wojciech Kozlowski Date: Sat, 14 Sep 2024 23:09:47 +0200 Subject: [PATCH] Submit on confirm not cancel --- src/tui/app/machine/input.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/tui/app/machine/input.rs b/src/tui/app/machine/input.rs index 169bf58..5653cf9 100644 --- a/src/tui/app/machine/input.rs +++ b/src/tui/app/machine/input.rs @@ -24,14 +24,14 @@ impl IAppInput for AppInputMode { self.app } - fn confirm(self) -> Self::APP { - self.cancel() - } - - fn cancel(mut self) -> Self::APP { + fn confirm(mut self) -> Self::APP { if let AppState::Match(state) = &mut self.app { state.submit_input(self.input) }; self.app } + + fn cancel(self) -> Self::APP { + self.app + } }