From 50c70a3ef2bc56aa039f42f4d01f636bda5cebb0 Mon Sep 17 00:00:00 2001 From: friendica Date: Tue, 2 Jul 2013 21:30:27 -0700 Subject: only show tag cloud for visible items --- include/taxonomy.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/taxonomy.php b/include/taxonomy.php index d4bb97b3e..1f2b30731 100644 --- a/include/taxonomy.php +++ b/include/taxonomy.php @@ -97,13 +97,13 @@ function format_term_for_display($term) { function tagadelic($uid, $count = 0, $flags = 0, $type = TERM_HASHTAG) { -dbg(1); + if($flags) $sql_options = " and (item_flags & " . intval($flags) . ") "; // Fetch tags $r = q("select term, count(term) as total from term left join item on term.oid = item.id where term.uid = %d and term.type = %d - and otype = %d + and otype = %d and item_restrict = 0 $sql_options group by term order by total desc %s", intval($uid), @@ -111,7 +111,7 @@ dbg(1); intval(TERM_OBJ_POST), ((intval($count)) ? "limit $count" : '') ); -dbg(0); + if(! $r) return array(); -- cgit v1.2.3