aboutsummaryrefslogtreecommitdiff
path: root/engine/lib
diff options
context:
space:
mode:
authorkevinjardine <kevinjardine@36083f99-b078-4883-b0ff-0f9b5a30f544>2009-03-04 10:57:14 +0000
committerkevinjardine <kevinjardine@36083f99-b078-4883-b0ff-0f9b5a30f544>2009-03-04 10:57:14 +0000
commita81120c8381afc626137adb4268cea83685c38ff (patch)
tree7e8aa05cc31b65a2eb27c0a688994c6b07891460 /engine/lib
parent6885e40ad851e4480b18e57a6b7f7f4cec02cc64 (diff)
downloadelgg-a81120c8381afc626137adb4268cea83685c38ff.tar.gz
elgg-a81120c8381afc626137adb4268cea83685c38ff.tar.bz2
get_tags now uses get_access_sql_suffix for access control.
git-svn-id: https://code.elgg.org/elgg/trunk@3055 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/lib')
-rw-r--r--engine/lib/tags.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/engine/lib/tags.php b/engine/lib/tags.php
index ed04f579c..d819bb0e6 100644
--- a/engine/lib/tags.php
+++ b/engine/lib/tags.php
@@ -105,7 +105,7 @@
$site_guid = $CONFIG->site_id;
}
- $access = get_access_list();
+ //$access = get_access_list();
$query = "SELECT msvalue.string as tag, count(msvalue.id) as total ";
$query .= "FROM {$CONFIG->dbprefix}entities e join {$CONFIG->dbprefix}metadata md on md.entity_guid = e.guid ";
@@ -133,7 +133,8 @@
}
$userid = get_loggedin_userid();
- $query .= " and (e.access_id in {$access} or (e.access_id = " . ACCESS_PRIVATE . " and e.owner_guid = {$userid}))";
+ //$query .= " and (e.access_id in {$access} or (e.access_id = " . ACCESS_PRIVATE . " and e.owner_guid = {$userid}))";
+ $query .= ' and ' . get_access_sql_suffix("e"); // Add access controls
$query .= " group by msvalue.string having total > {$threshold} order by total desc limit {$limit} ";