From 191705a96418d7342273852f579c7747efcab449 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Sat, 24 May 2014 13:41:11 +0000 Subject: [PATCH] Fix inversed logic in Walker_Category::start_el(). see [28359]. Correct 'use_desc_for_title' parameter description. see #26557. git-svn-id: https://develop.svn.wordpress.org/trunk@28572 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/category-template.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/wp-includes/category-template.php b/src/wp-includes/category-template.php index 9eef28efe6..ffaa039d62 100644 --- a/src/wp-includes/category-template.php +++ b/src/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. *