master
Aevann1 2022-04-22 17:08:42 +02:00
parent bc762ff06c
commit 6b97488355
2 changed files with 3 additions and 2 deletions

View File

@ -39,8 +39,7 @@ def get_logged_in_user():
def check_ban_evade(v):
if v and not v.patron and v.admin_level < 2 and v.ban_evade and not v.unban_utc:
if randint(0,30) < v.ban_evade: v.shadowbanned = "AutoJanny"
else: v.ban_evade +=1
v.shadowbanned = "AutoJanny"
g.db.add(v)
g.db.commit()

View File

@ -991,10 +991,12 @@ def shadowban(user_id, v):
if user.admin_level != 0: abort(403)
user.shadowbanned = v.username
g.db.add(user)
for alt in user.alts:
if alt.admin_level: break
alt.shadowbanned = v.username
g.db.add(alt)
ma = ModAction(
kind="shadowban",
user_id=v.id,