From aa1cc8fb5fa5277286632bcb94aec81f13f962d3 Mon Sep 17 00:00:00 2001 From: Aevann Date: Sat, 25 Mar 2023 22:40:45 +0200 Subject: [PATCH] buff fake votes a bit --- files/routes/routehelpers.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/files/routes/routehelpers.py b/files/routes/routehelpers.py index 337d5a557..215500b52 100644 --- a/files/routes/routehelpers.py +++ b/files/routes/routehelpers.py @@ -109,14 +109,15 @@ def execute_shadowban_viewers_and_voters(v:Optional[User], target:Union[Submissi if not v or not v.shadowbanned: return if not target: return if v.id != target.author_id: return - if not (86400 > time.time() - target.created_utc > 60): return - ti = max(int((time.time() - target.created_utc)/60), 1) + if not (86400 > time.time() - target.created_utc > 20): + return + + ti = max(int((time.time() - target.created_utc)/60), 3) max_upvotes = min(ti, 13) rand = randint(0, max_upvotes) if target.upvotes >= rand: return amount = randint(0, 3) - if amount != 1: return target.upvotes += amount if isinstance(target, Submission):