Skip to content

Commit

Permalink
Coding Standards: Apply various alignment corrections from `composer …
Browse files Browse the repository at this point in the history
…format`.

This fixes a few WPCS warnings along the lines of:
* Array double arrow not aligned correctly
* Equals sign not aligned with surrounding statements
* Usage of ELSE IF is discouraged; use ELSEIF instead

Follow-up to [55099], [55192], [55194], [55271].

Props davidbaumwald, jrf, SergeyBiryukov.
Fixes #57994.
Built from https://develop.svn.wordpress.org/trunk@55606


git-svn-id: http://core.svn.wordpress.org/trunk@55118 1a063a9b-81f0-0310-95a4-ce76da25c4cd
  • Loading branch information
SergeyBiryukov committed Mar 29, 2023
1 parent 08e9393 commit f940bc8
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 13 deletions.
12 changes: 6 additions & 6 deletions wp-admin/user-edit.php
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@
</tr>

<?php
$languages = get_available_languages();
$languages = get_available_languages();
$can_install_translations = current_user_can( 'install_languages' ) && wp_can_install_language_pack();
?>
<?php if ( $languages || $can_install_translations ) : ?>
Expand All @@ -370,12 +370,12 @@

wp_dropdown_languages(
array(
'name' => 'locale',
'id' => 'locale',
'selected' => $user_locale,
'languages' => $languages,
'name' => 'locale',
'id' => 'locale',
'selected' => $user_locale,
'languages' => $languages,
'show_available_translations' => $can_install_translations,
'show_option_site_default' => true,
'show_option_site_default' => true,
)
);
?>
Expand Down
4 changes: 2 additions & 2 deletions wp-includes/block-template-utils.php
Original file line number Diff line number Diff line change
Expand Up @@ -1338,9 +1338,9 @@ function get_template_hierarchy( $slug, $is_custom = false, $template_prefix = '
if ( $slug !== $type ) {
$template_hierarchy[] = $type;
}
} else if ( preg_match( '/^(author|category|archive|tag|page)-.+$/', $slug, $matches ) ) {
} elseif ( preg_match( '/^(author|category|archive|tag|page)-.+$/', $slug, $matches ) ) {
$template_hierarchy[] = $matches[1];
} else if ( preg_match( '/^(taxonomy|single)-(.+)$/', $slug, $matches ) ) {
} elseif ( preg_match( '/^(taxonomy|single)-(.+)$/', $slug, $matches ) ) {
$type = $matches[1];
$slug_remaining = $matches[2];

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ public function update_item( $request ) {
return $changes;
}

$result = wp_update_post( wp_slash( (array) $changes ), true, false );
$result = wp_update_post( wp_slash( (array) $changes ), true, false );
if ( is_wp_error( $result ) ) {
return $result;
}
Expand Down
6 changes: 3 additions & 3 deletions wp-includes/script-loader.php
Original file line number Diff line number Diff line change
Expand Up @@ -1108,9 +1108,9 @@ function wp_default_scripts( $scripts ) {
$scripts->add( 'mediaelement-vimeo', '/wp-includes/js/mediaelement/renderers/vimeo.min.js', array( 'mediaelement' ), '4.2.17', 1 );
$scripts->add( 'wp-mediaelement', "/wp-includes/js/mediaelement/wp-mediaelement$suffix.js", array( 'mediaelement' ), false, 1 );
$mejs_settings = array(
'pluginPath' => includes_url( 'js/mediaelement/', 'relative' ),
'classPrefix' => 'mejs-',
'stretching' => 'responsive',
'pluginPath' => includes_url( 'js/mediaelement/', 'relative' ),
'classPrefix' => 'mejs-',
'stretching' => 'responsive',
/** This filter is documented in wp-includes/media.php */
'audioShortcodeLibrary' => apply_filters( 'wp_audio_shortcode_library', 'mediaelement' ),
/** This filter is documented in wp-includes/media.php */
Expand Down
2 changes: 1 addition & 1 deletion wp-includes/version.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.3-alpha-55601';
$wp_version = '6.3-alpha-55606';

/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
Expand Down

0 comments on commit f940bc8

Please sign in to comment.