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)