mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
More custom post type support. Props scribu. see #9674
git-svn-id: https://develop.svn.wordpress.org/trunk@12597 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -2062,8 +2062,13 @@ class WP_Query {
|
||||
|
||||
if ( is_array($post_type) )
|
||||
$post_type_cap = 'multiple_post_type';
|
||||
else
|
||||
$post_type_cap = $post_type;
|
||||
else {
|
||||
$post_type_object = get_post_type_object ( $post_type );
|
||||
if ( !empty($post_type_object) )
|
||||
$post_type_cap = $post_type_object->capability_type;
|
||||
else
|
||||
$post_type_cap = $post_type;
|
||||
}
|
||||
|
||||
$exclude_post_types = '';
|
||||
foreach ( get_post_types( array('exclude_from_search' => true) ) as $_wp_post_type )
|
||||
|
||||
Reference in New Issue
Block a user