From 230c1c5c8ade89ffca980ce83d21042a501d3712 Mon Sep 17 00:00:00 2001 From: desrosj Date: Tue, 2 Feb 2021 18:04:03 +0000 Subject: [PATCH] Coding Standards: Fix several minor coding standards issues. These are made by running `composer format`. Follow up to [50124], [50129], [50143]. See #49961, #52192, #34281. Built from https://develop.svn.wordpress.org/trunk@50152 git-svn-id: http://core.svn.wordpress.org/trunk@49831 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/cron.php | 4 ++-- wp-includes/media.php | 2 +- .../endpoints/class-wp-rest-attachments-controller.php | 8 ++++---- wp-includes/script-loader.php | 4 ++-- wp-includes/version.php | 2 +- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/wp-includes/cron.php b/wp-includes/cron.php index ae134969f7..c0c9664ca4 100644 --- a/wp-includes/cron.php +++ b/wp-includes/cron.php @@ -544,7 +544,7 @@ function wp_clear_scheduled_hook( $hook, $args = array(), $wp_error = false ) { // Previously, this function took the arguments as discrete vars rather than an array like the rest of the API. if ( ! is_array( $args ) ) { _deprecated_argument( __FUNCTION__, '3.0.0', __( 'This argument has changed to an array to match the behavior of the other cron functions.' ) ); - $args = array_slice( func_get_args(), 1 ); // phpcs:ignore PHPCompatibility.FunctionUse.ArgumentFunctionsReportCurrentValue.NeedsInspection + $args = array_slice( func_get_args(), 1 ); // phpcs:ignore PHPCompatibility.FunctionUse.ArgumentFunctionsReportCurrentValue.NeedsInspection $wp_error = false; } @@ -1182,7 +1182,7 @@ function _get_cron_array() { */ function _set_cron_array( $cron, $wp_error = false ) { $cron['version'] = 2; - $result = update_option( 'cron', $cron ); + $result = update_option( 'cron', $cron ); if ( $wp_error && ! $result ) { return new WP_Error( diff --git a/wp-includes/media.php b/wp-includes/media.php index 093e7bc4ff..b22e04f3e3 100644 --- a/wp-includes/media.php +++ b/wp-includes/media.php @@ -4986,7 +4986,7 @@ function wp_getimagesize( $filename, &$imageinfo = array() ) { /* * Silencing notice and warning is intentional. * - * getimagesize() has a tendency to generate errors, such as + * getimagesize() has a tendency to generate errors, such as * "corrupt JPEG data: 7191 extraneous bytes before marker", * even when it's able to provide image size information. * diff --git a/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php b/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php index 4f55c6a577..ea4ae947cc 100644 --- a/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php +++ b/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php @@ -1335,8 +1335,8 @@ class WP_REST_Attachments_Controller extends WP_REST_Posts_Controller { ), 'oneOf' => array( array( - 'title' => __( 'Rotation' ), - 'properties' => array( + 'title' => __( 'Rotation' ), + 'properties' => array( 'type' => array( 'description' => __( 'Rotation type.' ), 'type' => 'string', @@ -1358,8 +1358,8 @@ class WP_REST_Attachments_Controller extends WP_REST_Posts_Controller { ), ), array( - 'title' => __( 'Crop' ), - 'properties' => array( + 'title' => __( 'Crop' ), + 'properties' => array( 'type' => array( 'description' => __( 'Crop type.' ), 'type' => 'string', diff --git a/wp-includes/script-loader.php b/wp-includes/script-loader.php index 9d9fe39825..3a9ac203de 100644 --- a/wp-includes/script-loader.php +++ b/wp-includes/script-loader.php @@ -1083,8 +1083,8 @@ function wp_default_scripts( $scripts ) { 'user-profile', 'userProfileL10n', array( - 'user_id' => $user_id, - 'nonce' => wp_create_nonce( 'reset-password-for-' . $user_id ), + 'user_id' => $user_id, + 'nonce' => wp_create_nonce( 'reset-password-for-' . $user_id ), ) ); diff --git a/wp-includes/version.php b/wp-includes/version.php index 9a839b0560..76ccea18fb 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -13,7 +13,7 @@ * * @global string $wp_version */ -$wp_version = '5.7-alpha-50151'; +$wp_version = '5.7-alpha-50152'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.