From: Roland Häder Date: Mon, 24 Jul 2023 05:04:51 +0000 (+0200) Subject: Optimized: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=6c296c3bade88f87dff8d2f5fbca5c99dfd1b95e;p=fba.git Optimized: - first simple checks then invoke methods - recheck_obfuscation() is about block lists, not instances, therefore we need to check 'last_blocked' timestamp --- diff --git a/fba/commands.py b/fba/commands.py index 6974862..08b9dda 100644 --- a/fba/commands.py +++ b/fba/commands.py @@ -1481,7 +1481,7 @@ def recheck_obfuscation(args: argparse.Namespace) -> int: logger.info("Checking %d domains ...", len(rows)) for row in rows: logger.debug("Fetching peers from domain='%s',software='%s',nodeinfo_url='%s' ...", row["domain"], row["software"], row["nodeinfo_url"]) - if (args.force is None or not args.force) and instances.is_recent(row["domain"]) and args.domain is None and args.software is None: + if (args.force is None or not args.force) and args.domain is None and args.software is None and instances.is_recent(row["domain"], "last_blocked"): logger.debug("row[domain]='%s' has been recently checked, args.force[]='%s' - SKIPPED!", row["domain"], type(args.force)) continue