From 6ab398733b00d62bbefe4467f238f85b3f610f70 Mon Sep 17 00:00:00 2001 From: Matt Mullenweg Date: Mon, 12 Jan 2004 09:35:41 +0000 Subject: [PATCH] Fix from TheJason for duplicate entries when cats are specified. git-svn-id: https://develop.svn.wordpress.org/trunk@756 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-blog-header.php | 1 + 1 file changed, 1 insertion(+) diff --git a/wp-blog-header.php b/wp-blog-header.php index 8811053629..d9b1ca414f 100644 --- a/wp-blog-header.php +++ b/wp-blog-header.php @@ -304,6 +304,7 @@ if (isset($user_ID) && ('' != intval($user_ID))) $where .= " OR post_author = $user_ID AND post_status != 'draft')"; else $where .= ')'; +$where .= " GROUP BY $tableposts.ID"; $request = " SELECT $distinct * FROM $tableposts $join WHERE 1=1".$where." ORDER BY post_$orderby $limits";