diff options
author | marcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-04-23 16:01:19 +0000 |
---|---|---|
committer | marcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-04-23 16:01:19 +0000 |
commit | 214864e2c5308fb87611f99141c2e2b3747b87d7 (patch) | |
tree | de0fcd9420aa665a140a3b550f4cd22d8cc1f4ed /engine/lib | |
parent | d71653498c6a35a944d29025c4c79b128da3fb9a (diff) | |
download | elgg-214864e2c5308fb87611f99141c2e2b3747b87d7.tar.gz elgg-214864e2c5308fb87611f99141c2e2b3747b87d7.tar.bz2 |
Closes #980: group_gatekeeper() now has an admin override if the admin is logged in
git-svn-id: https://code.elgg.org/elgg/trunk@3230 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/lib')
-rw-r--r-- | engine/lib/group.php | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/engine/lib/group.php b/engine/lib/group.php index 9e0843776..bbd7fba57 100644 --- a/engine/lib/group.php +++ b/engine/lib/group.php @@ -784,10 +784,13 @@ if ($group = page_owner_entity()) {
if ($group instanceof ElggGroup) {
$url = $group->getURL();
- if (
+ if ( ((!isloggedin()) && (!$group->isPublicMembership())) ||
((!$group->isMember(get_loggedin_user()) && (!$group->isPublicMembership())))
- ) $allowed = false;
+ ) $allowed = false; + + // Admin override + if (isadminloggedin()) $allowed = true;
}
}
|