diff --git a/wp-admin/edit-tags.php b/wp-admin/edit-tags.php
index b575a838d9..dbd630af56 100644
--- a/wp-admin/edit-tags.php
+++ b/wp-admin/edit-tags.php
@@ -544,7 +544,7 @@ do_action( "{$taxonomy}_add_form", $taxonomy );
/* translators: %s: default category */
__( 'Deleting a category does not delete the posts in that category. Instead, posts that were only assigned to the deleted category are set to the category %s.' ),
/** This filter is documented in wp-includes/category-template.php */
- '' . apply_filters( 'the_category', get_cat_name( get_option( 'default_category') ) ) . ' '
+ '' . apply_filters( 'the_category', get_cat_name( get_option( 'default_category') ), '', '' ) . ' '
);
?>
diff --git a/wp-admin/includes/class-walker-category-checklist.php b/wp-admin/includes/class-walker-category-checklist.php
index 966244eb78..3ed2a493dd 100644
--- a/wp-admin/includes/class-walker-category-checklist.php
+++ b/wp-admin/includes/class-walker-category-checklist.php
@@ -96,14 +96,14 @@ class Walker_Category_Checklist extends Walker {
$output .= "\n" . '' .
'' .
- esc_html( apply_filters( 'the_category', $category->name ) ) . '
';
+ esc_html( apply_filters( 'the_category', $category->name, '', '' ) ) . '';
} else {
/** This filter is documented in wp-includes/category-template.php */
$output .= "\n " .
' term_id, $args['selected_cats'] ), true, false ) .
disabled( empty( $args['disabled'] ), false, false ) . ' /> ' .
- esc_html( apply_filters( 'the_category', $category->name ) ) . ' ';
+ esc_html( apply_filters( 'the_category', $category->name, '', '' ) ) . '';
}
}
diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php
index 8385c90670..4846fcd906 100644
--- a/wp-admin/includes/template.php
+++ b/wp-admin/includes/template.php
@@ -214,7 +214,7 @@ function wp_popular_terms_checklist( $taxonomy, $default = 0, $number = 10, $ech
value="term_id; ?>" cap->assign_terms ) ); ?> />
name ) );
+ echo esc_html( apply_filters( 'the_category', $term->name, '', '' ) );
?>
@@ -255,7 +255,7 @@ function wp_link_category_checklist( $link_id = 0 ) {
$cat_id = $category->term_id;
/** This filter is documented in wp-includes/category-template.php */
- $name = esc_html( apply_filters( 'the_category', $category->name ) );
+ $name = esc_html( apply_filters( 'the_category', $category->name, '', '' ) );
$checked = in_array( $cat_id, $checked_categories ) ? ' checked="checked"' : '';
echo ' ', $name, " ";
}
diff --git a/wp-includes/category-template.php b/wp-includes/category-template.php
index 5a36067533..c9bf0d2f73 100644
--- a/wp-includes/category-template.php
+++ b/wp-includes/category-template.php
@@ -386,9 +386,10 @@ function wp_dropdown_categories( $args = '' ) {
*
* @see wp_dropdown_categories()
*
- * @param string $element Taxonomy element to list.
+ * @param string $element Category name.
+ * @param WP_Term|null $category The category object, or null if there's no corresponding category.
*/
- $show_option_none = apply_filters( 'list_cats', $r['show_option_none'] );
+ $show_option_none = apply_filters( 'list_cats', $r['show_option_none'], null );
$output .= "\t$show_option_none \n";
}
@@ -397,7 +398,7 @@ function wp_dropdown_categories( $args = '' ) {
if ( $r['show_option_all'] ) {
/** This filter is documented in wp-includes/category-template.php */
- $show_option_all = apply_filters( 'list_cats', $r['show_option_all'] );
+ $show_option_all = apply_filters( 'list_cats', $r['show_option_all'], null );
$selected = ( '0' === strval($r['selected']) ) ? " selected='selected'" : '';
$output .= "\t$show_option_all \n";
}
@@ -405,7 +406,7 @@ function wp_dropdown_categories( $args = '' ) {
if ( $r['show_option_none'] ) {
/** This filter is documented in wp-includes/category-template.php */
- $show_option_none = apply_filters( 'list_cats', $r['show_option_none'] );
+ $show_option_none = apply_filters( 'list_cats', $r['show_option_none'], null );
$selected = selected( $option_none_value, $r['selected'], false );
$output .= "\t$show_option_none \n";
}
diff --git a/wp-includes/version.php b/wp-includes/version.php
index d0a6c033c5..0ce1566a84 100644
--- a/wp-includes/version.php
+++ b/wp-includes/version.php
@@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
-$wp_version = '4.9-alpha-41220';
+$wp_version = '4.9-alpha-41221';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.