Add filter to get_categories(), props Malaiac, fixes #7427
git-svn-id: https://develop.svn.wordpress.org/trunk@9080 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
32a61c2b0a
commit
a515dfc9f0
|
@ -40,7 +40,7 @@ function &get_categories( $args = '' ) {
|
|||
$defaults = array( 'type' => 'category' );
|
||||
$args = wp_parse_args( $args, $defaults );
|
||||
|
||||
$taxonomy = 'category';
|
||||
$taxonomy = apply_filters( 'get_categories_taxonomy', 'category', $args );
|
||||
if ( 'link' == $args['type'] )
|
||||
$taxonomy = 'link_category';
|
||||
$categories = (array) get_terms( $taxonomy, $args );
|
||||
|
|
Loading…
Reference in New Issue