From 047013f92b5ff5840e8a0636766b4bb7e70c9aeb Mon Sep 17 00:00:00 2001 From: justcool393 Date: Wed, 5 Oct 2022 22:48:55 -0700 Subject: [PATCH] patron perm and also move them around --- files/helpers/const.py | 3 ++- files/routes/static.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/files/helpers/const.py b/files/helpers/const.py index 750ee0e23..9c4167d04 100644 --- a/files/helpers/const.py +++ b/files/helpers/const.py @@ -158,10 +158,11 @@ PERMS = { # Minimum admin_level to perform action. 'VIEW_ALTS': 2, 'VIEW_PROFILE_VIEWS': 2, 'VIEW_SORTED_ADMIN_LIST': 3, - 'PRINT_MARSEYBUX_FOR_KIPPY_ON_PCMEMES': 3, 'VIEW_ACTIVE_USERS': 2, 'VIEW_ALL_USERS': 2, 'VIEW_ALT_VOTES': 2, + 'VIEW_PATRONS': 3, # note: extra check for Aevann, carp, or snakes + 'PRINT_MARSEYBUX_FOR_KIPPY_ON_PCMEMES': 3, 'MERGE_USERS': 3, # note: extra check for Aevann 'ADMIN_ADD': 3, # note: explicitly disabled on rDrama 'ADMIN_REMOVE': 3, diff --git a/files/routes/static.py b/files/routes/static.py index 97c286f19..bc5b1d4d3 100644 --- a/files/routes/static.py +++ b/files/routes/static.py @@ -107,7 +107,7 @@ def daily_chart(v): @app.get("/patrons") @app.get("/paypigs") -@admin_level_required(3) +@admin_level_required(PERMS['VIEW_PATRONS']) def patrons(v): if AEVANN_ID and v.id not in (AEVANN_ID, CARP_ID, SNAKES_ID): abort(404)