diff --git a/wp-includes/taxonomy.php b/wp-includes/taxonomy.php index 4cb03baf16..7ca31154a3 100644 --- a/wp-includes/taxonomy.php +++ b/wp-includes/taxonomy.php @@ -911,7 +911,7 @@ function &get_terms($taxonomies, $args = '') { $taxonomies = array($taxonomies); } - foreach ( (array) $taxonomies as $taxonomy ) { + foreach ( $taxonomies as $taxonomy ) { if ( ! taxonomy_exists($taxonomy) ) { $error = & new WP_Error('invalid_taxonomy', __('Invalid Taxonomy')); return $error; @@ -940,6 +940,8 @@ function &get_terms($taxonomies, $args = '') { $args['pad_counts'] = false; } + $args = apply_filters( 'get_terms_args', $args, $taxonomies ); + extract($args, EXTR_SKIP); if ( $child_of ) {