Skip to content

Commit

Permalink
fix filters
Browse files Browse the repository at this point in the history
  • Loading branch information
datawhores committed Aug 27, 2024
1 parent fb4e97d commit 09916cc
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions ofscraper/commands/managers/db.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,12 @@ async def get_all_media(self):
def filter_media(self) :
self.log.info(f"filtering media for {self.username}_{self.model_id}")
args=read_args.retriveArgs()
medias=self.media
if args.downloaded:
self.media=[media for media in self.media if media["downloaded"]]
medias=[media for media in medias if media["downloaded"]]
elif args.not_downloaded:
self.media=[media for media in self.media if not media["downloaded"]]
medias=[media for media in medias if not media["downloaded"]]
self.media=medias



Expand Down

0 comments on commit 09916cc

Please sign in to comment.