[wp-trac] [WordPress Trac] #35382: get_terms with set fields 'id=>parent' not return the id key

WordPress Trac noreply at wordpress.org
Sun Jan 10 04:05:28 UTC 2016


#35382: get_terms with set fields 'id=>parent' not return the id key
--------------------------------------+---------------------------
 Reporter:  fantasyworld              |       Owner:  boonebgorges
     Type:  defect (bug)              |      Status:  closed
 Priority:  normal                    |   Milestone:  4.5
Component:  Taxonomy                  |     Version:  2.7.1
 Severity:  normal                    |  Resolution:  fixed
 Keywords:  good-first-bug has-patch  |     Focuses:
--------------------------------------+---------------------------
Changes (by boonebgorges):

 * owner:   => boonebgorges
 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"36252"]:
 {{{
 #!CommitTicketReference repository="" revision="36252"
 Don't reset index keys when trimming results of term queries.

 `array_slice()` must be told to preserve keys when the query results
 exceed the
 limit specified the 'number' parameter, so that `id=>parent` and other
 id-indexed return value formats don't get mangled.

 Props fantasyworld, wpdelighter.
 Fixes #35382.
 }}}

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


More information about the wp-trac mailing list