diff options
Diffstat (limited to 'src/components/smart_summary.rs')
-rw-r--r-- | src/components/smart_summary.rs | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/components/smart_summary.rs b/src/components/smart_summary.rs index 5b98186..de6eb91 100644 --- a/src/components/smart_summary.rs +++ b/src/components/smart_summary.rs @@ -228,7 +228,7 @@ impl Component for SmartSummaryButton { Input::ButtonPressed => { let settings = gio::Settings::new(crate::APPLICATION_ID); if !settings.get::<bool>("smart-summary-show-warning") { - return self.update(Input::WarningAccepted, sender, _root); + self.update(Input::WarningAccepted, sender, _root) } else { // TODO: show warning dialog let skip_warning_checkbox = gtk::CheckButton::with_label( @@ -258,11 +258,8 @@ impl Component for SmartSummaryButton { None::<&gio::Cancellable>, glib::clone!( #[strong] sender, - move |res| match res.as_str() { - "continue" => { - sender.input(Input::WarningAccepted); - }, - _ => {}, + move |res| if res.as_str() == "continue" { + sender.input(Input::WarningAccepted); } )) } |