[wp-trac] [WordPress Trac] #16137: wp_list_filter() is inexact when dealing with nested arrays
WordPress Trac
wp-trac at lists.automattic.com
Fri Jan 7 15:23:24 UTC 2011
#16137: wp_list_filter() is inexact when dealing with nested arrays
--------------------------+---------------------------------
Reporter: scribu | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Future Release
Component: General | Version:
Severity: normal | Keywords: has-patch 3.2-early
--------------------------+---------------------------------
To reproduce:
{{{
add_action('init', 'test_admin_notices', 11);
function test_admin_notices() {
global $wp_taxonomies;
print_r( wp_filter_object_list( array_values( $wp_taxonomies ), array(
'object_type' => array( 'post' ) ), 'and', 'object_type' ) );
}
}}}
Doing a manual loop instead of using array_intersect_assoc() fixes the
problem.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/16137>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list