diff --git a/code/modules/admin/admin.dm b/code/modules/admin/admin.dm index e5e3da79080..052a6c9dad4 100644 --- a/code/modules/admin/admin.dm +++ b/code/modules/admin/admin.dm @@ -224,18 +224,16 @@ var/global/floorIsLava = 0 set name = "Player Notes" if (!istype(src,/datum/admins)) src = usr.client.holder - if (!istype(src,/datum/admins)) + if (!check_rights(R_ADMIN|R_MOD, 0)) //YW Edit, make sure you have admin or mod rights to mess with player notes to_chat(usr, "Error: you are not an admin!") - if (!check_rights(R_ADMIN|R_MOD)) //YW Edit, make sure you have admin or mod rights to mess with player notes return PlayerNotesPage(1) /datum/admins/proc/PlayerNotesFilter() if (!istype(src,/datum/admins)) src = usr.client.holder - if (!istype(src,/datum/admins)) + if (!check_rights(R_ADMIN|R_MOD, 0)) //YW Edit, make sure you have admin or mod rights to mess with player notes to_chat(usr, "Error: you are not an admin!") - if (!check_rights(R_ADMIN|R_MOD)) //YW Edit, make sure you have admin or mod rights to mess with player notes return var/filter = tgui_input_text(usr, "Filter string (case-insensitive regex)", "Player notes filter") PlayerNotesPage(1, filter) @@ -266,9 +264,8 @@ var/global/floorIsLava = 0 set name = "Show Player Info" if (!istype(src,/datum/admins)) src = usr.client.holder - if (!istype(src,/datum/admins)) + if (!check_rights(R_ADMIN|R_MOD, 0)) //YW Edit, make sure you have admin or mod rights to mess with player notes to_chat(usr, "Error: you are not an admin!") - if (!check_rights(R_ADMIN|R_MOD)) //YW Edit, make sure you have admin or mod rights to mess with player notes return var/datum/tgui_module/player_notes_info/A = new(src) diff --git a/code/modules/tgui/states/admin.dm b/code/modules/tgui/states/admin.dm index bfa877bc096..c0bbf5d9eec 100644 --- a/code/modules/tgui/states/admin.dm +++ b/code/modules/tgui/states/admin.dm @@ -12,6 +12,6 @@ GLOBAL_DATUM_INIT(tgui_admin_state, /datum/tgui_state/admin_state, new) /datum/tgui_state/admin_state/can_use_topic(src_object, mob/user) - if(check_rights_for(user.client, R_ADMIN|R_EVENT)) + if(check_rights_for(user.client, R_ADMIN|R_MOD|R_EVENT)) //YW Edit, make sure you have admin or mod rights to mess with player notes return STATUS_INTERACTIVE return STATUS_CLOSE