master
Aevann1 2022-09-22 21:42:09 +02:00
parent 8a8a67a059
commit f9fdeed771
1 changed files with 3 additions and 9 deletions

View File

@ -77,7 +77,9 @@ def get_logged_in_user():
g.v = v
if v: v.poor = session.get('poor')
if v:
v.poor = session.get('poor')
v.check_ban_evade()
if AEVANN_ID and request.headers.get("Cf-Ipcountry") == 'EG':
if v and not v.username.startswith('Aev'):
@ -95,8 +97,6 @@ def auth_desired(f):
def wrapper(*args, **kwargs):
v = get_logged_in_user()
v.check_ban_evade()
return make_response(f(*args, v=v, **kwargs))
wrapper.__name__ = f.__name__
@ -115,8 +115,6 @@ def auth_desired_with_logingate(f):
if not redir: redir = '/'
return redirect(redir)
v.check_ban_evade()
return make_response(f(*args, v=v, **kwargs))
wrapper.__name__ = f.__name__
@ -127,8 +125,6 @@ def auth_required(f):
v = get_logged_in_user()
if not v: abort(401)
v.check_ban_evade()
return make_response(f(*args, v=v, **kwargs))
wrapper.__name__ = f.__name__
@ -141,8 +137,6 @@ def is_not_permabanned(f):
v = get_logged_in_user()
if not v: abort(401)
v.check_ban_evade()
if v.is_suspended_permanently:
return {"error": "Internal server error"}, 500