[wp-trac] [WordPress Trac] #39354: Unable to filter term query args using `pre_get_terms` action
WordPress Trac
noreply at wordpress.org
Tue Jan 24 14:19:25 UTC 2017
#39354: Unable to filter term query args using `pre_get_terms` action
--------------------------+---------------------------
Reporter: jfarthing84 | Owner: boonebgorges
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 4.8
Component: Taxonomy | Version: 4.7
Severity: normal | Resolution: fixed
Keywords: has-patch | Focuses:
--------------------------+---------------------------
Comment (by littler.chicken):
A note, changeset 39625 breaks code which works in 4.7 and earlier:
{{{
$taxonomies = get_taxonomies();
$args = array( 'orderby' => 'count', 'order' => 'DESC' );
$terms = wp_get_object_terms( get_the_ID(), $taxonomies,
$args );
}}}
It may be that this code is faulty and deserves to break (properly using
`get_object_taxonomies()` works), but I thought I would mention it, in
case I'm not the only one affected.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/39354#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list