diff --git a/wp-includes/category-template.php b/wp-includes/category-template.php index 9eef28efe6..ffaa039d62 100644 --- a/wp-includes/category-template.php +++ b/wp-includes/category-template.php @@ -444,7 +444,7 @@ function wp_dropdown_categories( $args = '' ) { * 'hide_empty' (bool|int) default is 1 - Whether to hide categories that * don't have any posts attached to them. * 'use_desc_for_title' (bool|int) default is 1 - Whether to use the - * description instead of the category title. + * category description as the title attribute. * 'feed' - See {@link get_categories()}. * 'feed_type' - See {@link get_categories()}. * 'feed_image' - See {@link get_categories()}. @@ -972,9 +972,7 @@ class Walker_Category extends Walker { ); $link = 'description ) ) { - $link .= ''; - } else { + if ( $args['use_desc_for_title'] && ! empty( $category->description ) ) { /** * Filter the category description for display. *