Add R_VIEWLOGS permission. (#29613)

This commit is contained in:
warriorstar-orion
2025-06-14 17:05:16 -04:00
committed by GitHub
parent 99fd4918d7
commit 64bf2b0fda
3 changed files with 10 additions and 3 deletions
+6
View File
@@ -274,6 +274,10 @@ GLOBAL_LIST_INIT(view_runtimes_verbs, list(
/client/proc/visualize_interesting_turfs,
/client/proc/profile_code
))
GLOBAL_LIST_INIT(view_logs_verbs, list(
/client/proc/getserverlogs,
/client/proc/get_server_logs_by_round_id,
))
/client/proc/add_admin_verbs()
if(holder)
@@ -323,6 +327,8 @@ GLOBAL_LIST_INIT(view_runtimes_verbs, list(
control_freak = 0
if(holder.rights & R_DEV_TEAM)
add_verb(src, GLOB.admin_verbs_dev)
if(holder.rights & R_VIEWLOGS)
add_verb(src, GLOB.view_logs_verbs)
if(is_connecting_from_localhost())
add_verb(src, /client/proc/export_current_character)
+2 -2
View File
@@ -4,7 +4,7 @@
set desc = "View/retrieve logfiles."
set category = "Admin"
if(!check_rights(R_ADMIN))
if(!check_rights(R_ADMIN|R_VIEWLOGS))
return
access_file_by_browsing_path(usr, "data/logs/")
@@ -15,7 +15,7 @@
set desc = "View/retrieve logfiles for a given round."
set category = "Admin"
if(!check_rights(R_ADMIN))
if(!check_rights(R_ADMIN|R_VIEWLOGS))
return
var/round_id = input(usr, "Enter a round ID.", "Enter Round ID", "[GLOB.round_id]") as null|text