Skip to content

Commit

Permalink
Drupal: Fixed bug in comment goto code.
Browse files Browse the repository at this point in the history
Fixed bug in pagination where hidden comments would result in incorrect page number for the drupal goto.

Fixes: https://dev.gridrepublic.org/browse/DBOINCP-524
  • Loading branch information
Shawn Kwang committed Apr 27, 2020
1 parent 0900f7e commit df966c7
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1671,7 +1671,7 @@ function boinccore_url_pagination_handler($type, $object_id = NULL) {
// See how many comments there are before (or after) this comment...
$comment_offset = db_result(db_query('
SELECT COUNT(*) FROM {comments}
WHERE nid = %d AND status = 0 AND timestamp %s %d',
WHERE nid = %d AND (status = 0 OR status = 1) AND timestamp %s %d',
$object->nid, $gt_lt, $object->timestamp));
if ($comment_offset) {
// Get the number of comments per page
Expand Down

0 comments on commit df966c7

Please sign in to comment.