From 8a000372bdfed83edf4e62b284433b8c05bc47d5 Mon Sep 17 00:00:00 2001 From: icewing Date: Thu, 3 Apr 2008 13:53:28 +0000 Subject: Marcus Povey * Bugfixes git-svn-id: https://code.elgg.org/elgg/trunk@392 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/lib/entities.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'engine') diff --git a/engine/lib/entities.php b/engine/lib/entities.php index ce5121d71..4b9473b7e 100644 --- a/engine/lib/entities.php +++ b/engine/lib/entities.php @@ -643,11 +643,11 @@ $where[] = "subtype=$subtype"; if ($owner_guid != "") $where[] = "owner_guid='$owner_guid'"; - + $query = "SELECT * from {$CONFIG->dbprefix}entities where "; foreach ($where as $w) $query .= " $w and "; - $query .= " (access_id in {$access} or (access_id = 0 and owner_guid = {$_SESSION['guid']}))"; // Add access controls + $query .= " (access_id in {$access} or (access_id = 0 and owner_guid = {$_SESSION['id']}))"; // Add access controls $query .= " order by $order_by limit $offset, $limit"; // Add order and limit $dt = get_data($query, "entity_row_to_elggstar"); -- cgit v1.2.3