From aaba77b5771012dea5f00257811f73a4f6b5c0cc Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Sun, 1 Oct 2023 00:22:27 +0000 Subject: [PATCH] Coding Standards: Remove redundant ignore annotations, take 4. This removes ignore annotations related to sniffs which are not used by WP Core (like sniffs in the `WordPress-Extra` ruleset). Follow-up to [48072], [51003], [55204], [56714]. Props jrf. See #59161. Built from https://develop.svn.wordpress.org/trunk@56752 git-svn-id: http://core.svn.wordpress.org/trunk@56264 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/file.php | 1 - wp-admin/includes/post.php | 3 --- wp-includes/sitemaps/class-wp-sitemaps-renderer.php | 2 -- wp-includes/sitemaps/class-wp-sitemaps-stylesheet.php | 4 ++-- wp-includes/template-canvas.php | 2 +- wp-includes/version.php | 2 +- 6 files changed, 4 insertions(+), 10 deletions(-) diff --git a/wp-admin/includes/file.php b/wp-admin/includes/file.php index e6c8f0fd4a..7ea3619e07 100644 --- a/wp-admin/includes/file.php +++ b/wp-admin/includes/file.php @@ -2764,7 +2764,6 @@ function wp_opcache_invalidate_directory( $dir ) { __( '%s expects a non-empty string.' ), 'wp_opcache_invalidate_directory()' ); - // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_trigger_error trigger_error( $error_message ); } return; diff --git a/wp-admin/includes/post.php b/wp-admin/includes/post.php index dd447d9beb..cac831cbd9 100644 --- a/wp-admin/includes/post.php +++ b/wp-admin/includes/post.php @@ -2011,11 +2011,8 @@ function wp_autosave_post_revisioned_meta_fields( $new_autosave ) { * * Ignoring sanitization to avoid altering meta. Ignoring the nonce check because * this is hooked on inner core hooks where a valid nonce was already checked. - * - * @phpcs:disable WordPress.Security */ $posted_data = isset( $_POST['data']['wp_autosave'] ) ? $_POST['data']['wp_autosave'] : $_POST; - // phpcs:enable $post_type = get_post_type( $new_autosave['post_parent'] ); diff --git a/wp-includes/sitemaps/class-wp-sitemaps-renderer.php b/wp-includes/sitemaps/class-wp-sitemaps-renderer.php index 9f91a10b7c..10a1ef1e7f 100644 --- a/wp-includes/sitemaps/class-wp-sitemaps-renderer.php +++ b/wp-includes/sitemaps/class-wp-sitemaps-renderer.php @@ -131,7 +131,6 @@ class WP_Sitemaps_Renderer { if ( ! empty( $index_xml ) ) { // All output is escaped within get_sitemap_index_xml(). - // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped echo $index_xml; } } @@ -196,7 +195,6 @@ class WP_Sitemaps_Renderer { if ( ! empty( $sitemap_xml ) ) { // All output is escaped within get_sitemap_xml(). - // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped echo $sitemap_xml; } } diff --git a/wp-includes/sitemaps/class-wp-sitemaps-stylesheet.php b/wp-includes/sitemaps/class-wp-sitemaps-stylesheet.php index f752a7f55f..1bf10327b2 100644 --- a/wp-includes/sitemaps/class-wp-sitemaps-stylesheet.php +++ b/wp-includes/sitemaps/class-wp-sitemaps-stylesheet.php @@ -25,12 +25,12 @@ class WP_Sitemaps_Stylesheet { header( 'Content-Type: application/xml; charset=UTF-8' ); if ( 'sitemap' === $type ) { - // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- All content escaped below. + // All content is escaped below. echo $this->get_sitemap_stylesheet(); } if ( 'index' === $type ) { - // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- All content escaped below. + // All content is escaped below. echo $this->get_sitemap_index_stylesheet(); } diff --git a/wp-includes/template-canvas.php b/wp-includes/template-canvas.php index 55f03267c8..8f631e5a77 100644 --- a/wp-includes/template-canvas.php +++ b/wp-includes/template-canvas.php @@ -20,7 +20,7 @@ $template_html = get_the_block_template_html(); > - + diff --git a/wp-includes/version.php b/wp-includes/version.php index 9d71af5daf..5fb797f6e1 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.4-beta1-56751'; +$wp_version = '6.4-beta1-56752'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.