fixed a bug in the new oo page tree stuff

removed a bunch of crap that somehow got readded
added new stuff for autogroups
got rid of magic groups
This commit is contained in:
JT Smith 2004-02-04 02:36:12 +00:00
parent bd4bf924f2
commit 0cb06e0e17
18 changed files with 102 additions and 1548 deletions

View file

@ -262,11 +262,12 @@ sub isInGroup {
my ($gid, $uid, @data, %group, $groupId);
($gid, $uid) = @_;
$uid = $session{user}{userId} if ($uid eq "");
### The "Everyone" group automatically returns true.
#The next 3 checks are to increase performance. If this section were removed, everything would continue to work as normal.
if ($gid == 7) {
return 1;
}
### The "Visitor" group returns false, unless the user is visitor.
if ($gid == 1) {
if ($uid == 1) {
return 1;
@ -274,10 +275,12 @@ sub isInGroup {
return 0;
}
}
### The "Registered Users" group returns true if user is not visitor.
if ($gid==2 && $uid != 1) {
return 1;
}
### Use session to cache multiple lookups of the same group.
if ($session{isInGroup}{$gid}{$uid} || $session{isInGroup}{3}{$uid}) {
return 1;