From d3b745db5d8d10aa92f1e41f61adc1f7efdf0753 Mon Sep 17 00:00:00 2001 From: friendica Date: Tue, 2 Jul 2013 21:57:18 -0700 Subject: [PATCH] bitwise logic issue comparing with multiple bits --- include/taxonomy.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/taxonomy.php b/include/taxonomy.php index 1f2b30731..e9cc0faf4 100644 --- a/include/taxonomy.php +++ b/include/taxonomy.php @@ -99,7 +99,7 @@ function format_term_for_display($term) { function tagadelic($uid, $count = 0, $flags = 0, $type = TERM_HASHTAG) { if($flags) - $sql_options = " and (item_flags & " . intval($flags) . ") "; + $sql_options = " and ((item_flags & " . intval($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