Eliminate the use of `extract()` in `the_taxonomies()`. Adds unit test.

See #22400.

Built from https://develop.svn.wordpress.org/trunk@28421


git-svn-id: http://core.svn.wordpress.org/trunk@28248 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Scott Taylor 2014-05-15 05:25:14 +00:00
parent ee90a8c17c
commit e6fad96f5e
1 changed files with 2 additions and 3 deletions

View File

@ -3685,7 +3685,7 @@ function get_term_link( $term, $taxonomy = '') {
*
* @param array $args Override the defaults.
*/
function the_taxonomies($args = array()) {
function the_taxonomies( $args = array() ) {
$defaults = array(
'post' => 0,
'before' => '',
@ -3695,9 +3695,8 @@ function the_taxonomies($args = array()) {
);
$r = wp_parse_args( $args, $defaults );
extract( $r, EXTR_SKIP );
echo $before . join($sep, get_the_taxonomies($post, $r)) . $after;
echo $r['before'] . join( $r['sep'], get_the_taxonomies( $r['post'], $r ) ) . $r['after'];
}
/**