From 9ede795bd8eb3ef9de00102d2086d5fe1b7a7879 Mon Sep 17 00:00:00 2001 From: Michel Roux Date: Thu, 17 Nov 2022 01:12:13 +0100 Subject: [PATCH] Restrict by downloads --- commands/pygg.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/commands/pygg.py b/commands/pygg.py index 08a7825..85e1dfb 100644 --- a/commands/pygg.py +++ b/commands/pygg.py @@ -112,11 +112,15 @@ def search_ygg(query, multi, full): tds = tr.find_all("td") size = tds[5].get_text() + downloads = tds[6].get_text() name = tds[1].get_text().lower().strip() if parse_size(size) > parse_size(f"{args.size}Go"): continue + if int(downloads) < 10: + continue + if any(word.lower() in name for word in BLACKLIST_WORDS): continue