refactor: Refactored a handful of Option calls to use take instead

This commit is contained in:
2025-01-18 13:00:21 -07:00
parent fd35106df8
commit 652bbcd5d4
2 changed files with 6 additions and 11 deletions
+2 -3
View File
@@ -157,12 +157,11 @@ impl<'a> App<'a> {
async fn check_for_radarr_prompt_action(&mut self) {
if self.data.radarr_data.prompt_confirm {
self.data.radarr_data.prompt_confirm = false;
if let Some(radarr_event) = &self.data.radarr_data.prompt_confirm_action {
if let Some(radarr_event) = self.data.radarr_data.prompt_confirm_action.take() {
self
.dispatch_network_event(radarr_event.clone().into())
.dispatch_network_event(radarr_event.into())
.await;
self.should_refresh = true;
self.data.radarr_data.prompt_confirm_action = None;
}
}
}