Ticket #13109: wp_filter_object_list.diff
File wp_filter_object_list.diff, 593 bytes (added by , 14 years ago) |
---|
-
wp-includes/functions.php
2934 2934 foreach ( $list as $key => $obj ) { 2935 2935 $matched = count(array_intersect_assoc(get_object_vars($obj), $args)); 2936 2936 if ( ('and' == $operator && $matched == $count) || ('or' == $operator && $matched <= $count) ) 2937 $filtered[$key] = $field ? $obj->$field : $obj; 2937 if ( $field ) 2938 $filtered[] = $obj->$field; 2939 else 2940 $filtered[$key] = $obj; 2938 2941 } 2939 2942 2940 2943 return $filtered;