[wp-trac] [WordPress Trac] #53177: WP_User_Query does not accept fields as string except ID

WordPress Trac noreply at wordpress.org
Sat May 7 03:31:07 UTC 2022


#53177: WP_User_Query does not accept fields as string except ID
-------------------------------------------------+-------------------------
 Reporter:  rilwis                               |       Owner:  audrasjb
     Type:  defect (bug)                         |      Status:  closed
 Priority:  normal                               |   Milestone:  6.0
Component:  Users                                |     Version:  4.4
 Severity:  normal                               |  Resolution:  fixed
 Keywords:  has-testing-info has-dev-note has-   |     Focuses:  docs
  patch has-unit-tests needs-docs                |
-------------------------------------------------+-------------------------
Changes (by peterwilsoncc):

 * status:  reopened => closed
 * resolution:   => fixed


Comment:

 In [changeset:"53362" 53362]:
 {{{
 #!CommitTicketReference repository="" revision="53362"
 Users: Allow any DB field to be returned by `WP_User_Query`.

 Restore behaviour of `fields` parameter in `WP_User_Query` to allow
 developers to specify any database field to be returned either
 individually or as part of a subset. Add these fields to the
 documentation.

 When a subset of `fields` includes the `id` paramater, include it in the
 results in both upper and lowercase to maintain backward compatibility.

 Follow up to [53327].

 Props dd32, pbearne, kraftbj, peterwilsoncc.
 Fixes #53177.
 }}}

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


More information about the wp-trac mailing list