Make WordPress Core

Changeset 40924


Ignore:
Timestamp:
06/23/2017 02:05:19 AM (7 years ago)
Author:
boonebgorges
Message:

When querying for terms, do not assume that $taxonomies is a 0-indexed array.

In [25108], the logic of term queries was modified to avoid assuming
that the taxonomies array was numerically indexed. See #23506. This
fix was inadvertantly reverted during the refactor in [25162].

Props david.binda.
Fixes #41113.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-term-query.php

    r40900 r40924  
    430430                $excluded_children = array_merge(
    431431                    $excluded_children,
    432                     (array) get_terms( $taxonomies[0], array(
     432                    (array) get_terms( reset( $taxonomies ), array(
    433433                        'child_of' => intval( $extrunk ),
    434434                        'fields' => 'ids',
Note: See TracChangeset for help on using the changeset viewer.