refactor: Reduced the number of clones necessary when building modal structs

This commit is contained in:
2025-01-18 13:56:18 -07:00
parent 652bbcd5d4
commit fda69178b9
13 changed files with 203 additions and 276 deletions
@@ -22,9 +22,13 @@ pub(super) struct IndexerSettingsHandler<'a, 'b> {
impl<'a, 'b> IndexerSettingsHandler<'a, 'b> {
fn build_edit_indexer_settings_body(&mut self) -> IndexerSettings {
let indexer_settings = self.app.data.radarr_data.indexer_settings.clone().unwrap();
self.app.data.radarr_data.indexer_settings = None;
indexer_settings
self
.app
.data
.radarr_data
.indexer_settings
.take()
.expect("Indexer settings not found")
}
}