From a8e823cbe04ca170bd7d802445f2cfd6b22fb0b9 Mon Sep 17 00:00:00 2001 From: Feramance Date: Wed, 20 Sep 2023 15:08:14 +0200 Subject: [PATCH] [build] Deletion logic change --- qBitrr/arss.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/qBitrr/arss.py b/qBitrr/arss.py index 53d3a726..f60a689d 100755 --- a/qBitrr/arss.py +++ b/qBitrr/arss.py @@ -1425,9 +1425,7 @@ def db_update(self): if self.type == "sonarr": if not self.series_search: self.model_arr_file: EpisodesModel - Ids = [ - id for id in self.model_arr_file.select(self.model_arr_file.Id).execute() - ] + Ids = list(self.model_arr_file.select(self.model_arr_file.Id).execute()) self.model_file.delete().where(self.model_file.EntryId.not_in(Ids)).execute() _series = set() if self.search_by_year: @@ -1474,7 +1472,9 @@ def db_update(self): self.db_update_single_series(db_entry=series) else: self.model_arr_series_file: SeriesModel - Ids = [id for id in self.model_arr_series_file.select().execute()] + Ids = list( + self.model_arr_series_file.select(self.model_arr_series_file.Id).execute() + ) self.series_file_model.delete().where( self.series_file_model.EntryId.not_in(Ids) ).execute() @@ -1489,7 +1489,7 @@ def db_update(self): self.model_arr_file: MoviesModel elif self.version == "5": self.model_arr_file: MoviesModelv5 - Ids = [id for id in self.model_arr_file.select(self.model_arr_file.Id).execute()] + Ids = list(self.model_arr_file.select(self.model_arr_file.Id).execute()) self.model_file.delete().where(self.model_file.EntryId.not_in(Ids)).execute() if self.search_by_year: for movies in (