Skip to content

Commit

Permalink
Update tenancy_config.py for role checked endpoints
Browse files Browse the repository at this point in the history
class TenancyConfig(Resource):

GET: not required
POST: required (admin)
PATCH: required (admin)
DELETE: required (admin)

imageRequest GET: not required
  • Loading branch information
Ye-Tien authored Oct 1, 2023
1 parent e2d8778 commit 3251ad1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion controllers/tenancy_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ def patch(self):
toggle_config(session, args['id'])
return {'success': True}

@is_user_or_has_role('id', UserType.VOLUNTEER)
@is_user_or_has_role('id', UserType.VOLUNTEER, UserType.ROOT_ADMIN)
@marshal_with(config_fields)
def delete(self):
args = parser.parse_args()
Expand Down

0 comments on commit 3251ad1

Please sign in to comment.