From 6e59ccc47e99252cedef720546a095ae157bc06f Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Tue, 14 Feb 2023 15:46:18 +0000 Subject: [PATCH] Coding Standards: Rename the remaining `$cat_ID` variables to `$cat_id`. This resolves a few WPCS warnings: {{{ Variable "$cat_ID" is not in valid snake_case format, try "$cat_i_d" }}} Affected functions: * `wp_delete_category()` * `get_category_rss_link()` * `get_catname()` Follow-up to [836], [2068], [2551], [2695], [6365], [10959], [52958], [55190]. Fixes #56754. Built from https://develop.svn.wordpress.org/trunk@55334 git-svn-id: http://core.svn.wordpress.org/trunk@54867 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/deprecated.php | 12 ++++++------ wp-includes/taxonomy.php | 6 +++--- wp-includes/version.php | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/wp-includes/deprecated.php b/wp-includes/deprecated.php index 8faf82eeed..5526a97cbb 100644 --- a/wp-includes/deprecated.php +++ b/wp-includes/deprecated.php @@ -1150,13 +1150,13 @@ function comments_rss_link($link_text = 'Comments RSS') { * @see get_category_feed_link() * * @param bool $display - * @param int $cat_ID + * @param int $cat_id * @return string */ -function get_category_rss_link($display = false, $cat_ID = 1) { +function get_category_rss_link($display = false, $cat_id = 1) { _deprecated_function( __FUNCTION__, '2.5.0', 'get_category_feed_link()' ); - $link = get_category_feed_link($cat_ID, 'rss2'); + $link = get_category_feed_link($cat_id, 'rss2'); if ( $display ) echo $link; @@ -1248,12 +1248,12 @@ function get_commentdata( $comment_id, $no_cache = 0, $include_unapproved = fals * @deprecated 2.8.0 Use get_cat_name() * @see get_cat_name() * - * @param int $cat_ID Category ID + * @param int $cat_id Category ID * @return string category name */ -function get_catname( $cat_ID ) { +function get_catname( $cat_id ) { _deprecated_function( __FUNCTION__, '2.8.0', 'get_cat_name()' ); - return get_cat_name( $cat_ID ); + return get_cat_name( $cat_id ); } /** diff --git a/wp-includes/taxonomy.php b/wp-includes/taxonomy.php index bd83110e3f..f090b349ab 100644 --- a/wp-includes/taxonomy.php +++ b/wp-includes/taxonomy.php @@ -2154,13 +2154,13 @@ function wp_delete_term( $term, $taxonomy, $args = array() ) { * * @since 2.0.0 * - * @param int $cat_ID Category term ID. + * @param int $cat_id Category term ID. * @return bool|int|WP_Error Returns true if completes delete action; false if term doesn't exist; * Zero on attempted deletion of default Category; WP_Error object is * also a possibility. */ -function wp_delete_category( $cat_ID ) { - return wp_delete_term( $cat_ID, 'category' ); +function wp_delete_category( $cat_id ) { + return wp_delete_term( $cat_id, 'category' ); } /** diff --git a/wp-includes/version.php b/wp-includes/version.php index bc78ff956d..3ef4f66226 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.2-beta1-55333'; +$wp_version = '6.2-beta1-55334'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.