From 7adba38c3fe8ae35c4c79aa125b04d4427f13a72 Mon Sep 17 00:00:00 2001 From: Guy Brand Date: Tue, 12 Feb 2008 22:32:22 +0100 Subject: Have aclcheck use auth_isadmin darcs-hash:20080212213222-19e2d-d8a2261fa83d6482afe213ffb41611ae723811de.gz --- inc/auth.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/auth.php b/inc/auth.php index c44e2457d..027e9c685 100644 --- a/inc/auth.php +++ b/inc/auth.php @@ -349,7 +349,7 @@ function auth_aclcheck($id,$user,$groups){ $user = auth_nameencode($user); //if user is superuser return 255 (acl_admin) - if(auth_nameencode($conf['superuser']) == $user) { return AUTH_ADMIN; } + if(auth_isadmin($user,$groups)) { return AUTH_ADMIN; } //make sure groups is an array if(!is_array($groups)) $groups = array(); @@ -360,7 +360,7 @@ function auth_aclcheck($id,$user,$groups){ $groups[$i] = '@'.auth_nameencode($groups[$i]); } //if user is in superuser group return 255 (acl_admin) - if(in_array(auth_nameencode($conf['superuser'],true), $groups)) { return AUTH_ADMIN; } + if(auth_isadmin($user,$groups)) { return AUTH_ADMIN; } $ns = getNS($id); $perm = -1; -- cgit v1.2.3