﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc
10908	Impossible to exclude categries in a category listing	dimitryz	ryan	"Setting the 'category!__not_in' `query_var` in a `WP_Query` object does nothing if 'category_name' is also present. The consequence is that it's impossible to hide the posts of some child categories for a category listing.

The offending code is in line 1843:
{{{
$whichcat = "" AND $wpdb->term_taxonomy.taxonomy = 'category' "";
}}}

A dot (.) should be added before the equal (=) to indicate concatenation:
{{{
$whichcat .= "" AND $wpdb->term_taxonomy.taxonomy = 'category' "";
}}}

The proposed solution enabled the addition of categories ('category!__in') and exclusion of categories ('category!__not_in') when the following condition is met:

{{{
if ( '' != $q['category_name'] && !$this->is_singular ) {
}}}"	enhancement	closed	normal		Query	2.8	normal	duplicate	reporter-feedback	upyup
