From 44bf01151f7da193fd4f2d9c85554ddbe9e9c209 Mon Sep 17 00:00:00 2001 From: justcool393 Date: Wed, 5 Oct 2022 21:03:40 -0700 Subject: [PATCH] apparently this thing likes to commit without committing half of it ok --- files/helpers/const.py | 1 + files/routes/admin.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/files/helpers/const.py b/files/helpers/const.py index 9d4e1524e..6b073b502 100644 --- a/files/helpers/const.py +++ b/files/helpers/const.py @@ -153,6 +153,7 @@ PERMS = { # Minimum admin_level to perform action. 'ADMIN_ADD': 3, # note: explicitly disabled on rDrama 'ADMIN_REMOVE': 3, 'ADMIN_ADD_PERM_LEVEL': 2, # permission level given when user added via site + 'ADMIN_ACTIONS_REVERT': 3, } FEATURES = { diff --git a/files/routes/admin.py b/files/routes/admin.py index ae72346c4..cac8c6179 100644 --- a/files/routes/admin.py +++ b/files/routes/admin.py @@ -249,7 +249,7 @@ def distribute(v, option_id): @app.post("/@/revert_actions") @limiter.limit("1/second;30/minute;200/hour;1000/day") -@admin_level_required(3) +@admin_level_required(PERMS['ADMIN_ACTIONS_REVERT']) def revert_actions(v, username): user = get_user(username)