[wp-trac] [WordPress Trac] #59774: Undefined array key when using wp_list_pluck function

WordPress Trac noreply at wordpress.org
Sat Jun 22 23:43:51 UTC 2024


#59774: Undefined array key when using wp_list_pluck function
-------------------------------------------------+-------------------------
 Reporter:  iamarunchaitanyajami                 |       Owner:
                                                 |  hellofromTonya
     Type:  defect (bug)                         |      Status:  reopened
 Priority:  normal                               |   Milestone:  6.7
Component:  General                              |     Version:  5.1
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch has-unit-tests changes-    |     Focuses:
  requested early                                |
-------------------------------------------------+-------------------------

Comment (by Cybr):

 Should we not deprecate `wp_list_pluck()` altogether and encourage using
 the much faster `array_column()`?

 That function supports extracting from objects since PHP 7.0, and WP
 requires 7.4 or greater.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/59774#comment:34>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list