Make WordPress Core

Ticket #16895: 16895.diff

File 16895.diff, 534 bytes (added by dd32, 13 years ago)
  • wp-includes/functions.php

     
    30923092 * @return array
    30933093 */
    30943094function wp_list_pluck( $list, $field ) {
     3095        $field_values = array();
    30953096        foreach ( $list as $key => $value ) {
    30963097                $value = (array) $value;
    3097                 $list[ $key ] = $value[ $field ];
     3098                $field_values[ $key ] = $value[ $field ];
    30983099        }
    30993100
    3100         return $list;
     3101        return $field_values;
    31013102}
    31023103
    31033104/**