Ticket #16137: 16137.diff
| File 16137.diff, 639 bytes (added by scribu, 2 years ago) |
|---|
-
wp-includes/functions.php
3062 3062 $filtered = array(); 3063 3063 3064 3064 foreach ( $list as $key => $obj ) { 3065 $matched = count( array_intersect_assoc( (array) $obj, $args ) ); 3065 $to_match = (array) $obj; 3066 3067 $matched = 0; 3068 foreach ( $args as $m_key => $m_value ) { 3069 if ( $m_value == $to_match[$m_key] ) 3070 $matched++; 3071 } 3072 3066 3073 if ( ('and' == $operator && $matched == $count) || ('or' == $operator && $matched <= $count) ) { 3067 3074 $filtered[$key] = $obj; 3068 3075 }