Update index.html

Ryan Danenberg committed commit79beb7a7facba33557482218ab0fced25938e5de Browse files
1 file changed+4−0
index.html+4−0View file
@@ -1968,6 +1968,10 @@
}
function setAdminTab(tab) {
+ if (currentUser && currentUser.role !== 'admin') {
+ showToast('Access Denied', 'Only administrators have access to admin views.', 'error');
+ return;
+ }
currentAdminTab = tab;
['validation', 'projects'].forEach(t => {
const btn = document.getElementById(`a-tab-${t}`);