summaryrefslogtreecommitdiff
path: root/modules/taxonomy/taxonomy.module
diff options
context:
space:
mode:
authorSteven Wittens <steven@10.no-reply.drupal.org>2005-01-19 01:46:25 +0000
committerSteven Wittens <steven@10.no-reply.drupal.org>2005-01-19 01:46:25 +0000
commit09bd156ba212f56cc62de85c53f14127c719522b (patch)
tree226933be541577bc1d347cd1ae02c7a18b155673 /modules/taxonomy/taxonomy.module
parent86af977ecaebbed31d2897bdf6f3b829b0be924c (diff)
downloadbrdo-09bd156ba212f56cc62de85c53f14127c719522b.tar.gz
brdo-09bd156ba212f56cc62de85c53f14127c719522b.tar.bz2
- Fix tracker pager count query being wrong (it did not return a count but a set, and it counted nodes with more than 1 comment as multiple nodes).
- Clean up various SQL queries: removing literally inserted data (db_escape_string is evil!), fixing single "%" which should be "%%", fixing integers being compared as strings.
Diffstat (limited to 'modules/taxonomy/taxonomy.module')
-rw-r--r--modules/taxonomy/taxonomy.module2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/taxonomy/taxonomy.module b/modules/taxonomy/taxonomy.module
index ada11cbe3..b78ce043d 100644
--- a/modules/taxonomy/taxonomy.module
+++ b/modules/taxonomy/taxonomy.module
@@ -834,7 +834,7 @@ function taxonomy_select_nodes($tids = array(), $operator = 'or', $depth = 0, $p
$wheres .= ' AND tn'. $index .'.tid IN ('. implode(',', $tids) .')';
}
$sql = 'SELECT n.nid, n.sticky, n.created FROM {node} n '. $joins .' WHERE n.status = 1 '. $wheres .' ORDER BY n.sticky DESC, n.created DESC';
- $sql_count = 'SELECT COUNT(n.nid) FROM {node} n ' . $joins .' WHERE n.status = 1 ' . $wheres;
+ $sql_count = 'SELECT COUNT(n.nid) FROM {node} n '. $joins .' WHERE n.status = 1 ' . $wheres;
}
$sql = node_rewrite_sql($sql);
$sql_count = node_rewrite_sql($sql_count);