diff options
author | marcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-08-12 19:24:56 +0000 |
---|---|---|
committer | marcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-08-12 19:24:56 +0000 |
commit | 7f6be0148ec5f59de60cc14d1748aabcba2953e5 (patch) | |
tree | c83932eaf1bfd58af3efc69c8e755069ddc7aad2 /engine | |
parent | dfc668facbbe1c82440081fc3f556194ed0a7627 (diff) | |
download | elgg-7f6be0148ec5f59de60cc14d1748aabcba2953e5.tar.gz elgg-7f6be0148ec5f59de60cc14d1748aabcba2953e5.tar.bz2 |
Removed superadmin access controls. You can't call get_entity from within get_access_sql_suffix and get_access_array as it causes an infinite loop.
The only safe way to do this is via a plugin hook.
git-svn-id: https://code.elgg.org/elgg/trunk@1865 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine')
-rw-r--r-- | engine/lib/access.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/engine/lib/access.php b/engine/lib/access.php index f24a07cba..66eee69ed 100644 --- a/engine/lib/access.php +++ b/engine/lib/access.php @@ -83,10 +83,10 @@ if (!empty($collection->id)) $tmp_access_array[] = $collection->id;
}
- if ($user = get_entity($user_id)) {
+ /*if ($user = get_entity($user_id)) {
if ($user instanceof ElggUser && $user->admin)
$tmp_access_array[] = 0;
- }
+ }*/
$access_array[$user_id] = $tmp_access_array;
@@ -123,12 +123,12 @@ $owner = $_SESSION['id']; if (!$owner) $owner = -1;
- if ($owner_entity = get_entity($owner)) {
+ /*if ($owner_entity = get_entity($owner)) {
if ($owner_entity instanceof ElggUser)
if ($owner_entity->admin)
$sql = " (1 = 1) ";
}
- if (empty($sql))
+ if (empty($sql))*/
$sql = " ({$table_prefix}access_id in {$access} or ({$table_prefix}access_id = 0 and {$table_prefix}owner_guid = $owner))";
//}
//else
|