Skip to content

Commit 9594a46

Browse files
committed
only site admins can switch the indexer on and off
1 parent efd2e43 commit 9594a46

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

htsget_server/htsget_operations.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,8 @@ def indexer_status():
7575

7676

7777
def indexer_switch(status=None):
78+
if not authz.has_full_authz(connexion.request):
79+
return {"message": "User is not authorized to switch indexer"}, 403
7880
if status == "ON":
7981
try:
8082
open(INDEXING_SWITCH_FILE, "x")

0 commit comments

Comments
 (0)