Coding Standards: Use strict comparison in wp-admin/includes/class-walker-nav-menu-edit.php.

See #52627.
Built from https://develop.svn.wordpress.org/trunk@50767


git-svn-id: http://core.svn.wordpress.org/trunk@50376 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2021-04-17 12:22:03 +00:00
parent f7536fd387
commit ed067531ec
2 changed files with 4 additions and 4 deletions

View File

@ -92,7 +92,7 @@ class Walker_Nav_Menu_Edit extends Walker_Nav_Menu {
$classes = array( $classes = array(
'menu-item menu-item-depth-' . $depth, 'menu-item menu-item-depth-' . $depth,
'menu-item-' . esc_attr( $item->object ), 'menu-item-' . esc_attr( $item->object ),
'menu-item-edit-' . ( ( isset( $_GET['edit-menu-item'] ) && $item_id == $_GET['edit-menu-item'] ) ? 'active' : 'inactive' ), 'menu-item-edit-' . ( ( isset( $_GET['edit-menu-item'] ) && $item_id === $_GET['edit-menu-item'] ) ? 'active' : 'inactive' ),
); );
$title = $item->title; $title = $item->title;
@ -110,7 +110,7 @@ class Walker_Nav_Menu_Edit extends Walker_Nav_Menu {
$title = ( ! isset( $item->label ) || '' === $item->label ) ? $title : $item->label; $title = ( ! isset( $item->label ) || '' === $item->label ) ? $title : $item->label;
$submenu_text = ''; $submenu_text = '';
if ( 0 == $depth ) { if ( 0 === $depth ) {
$submenu_text = 'style="display: none;"'; $submenu_text = 'style="display: none;"';
} }
@ -157,7 +157,7 @@ class Walker_Nav_Menu_Edit extends Walker_Nav_Menu {
?> ?>
</span> </span>
<?php <?php
if ( isset( $_GET['edit-menu-item'] ) && $item_id == $_GET['edit-menu-item'] ) { if ( isset( $_GET['edit-menu-item'] ) && $item_id === $_GET['edit-menu-item'] ) {
$edit_url = admin_url( 'nav-menus.php' ); $edit_url = admin_url( 'nav-menus.php' );
} else { } else {
$edit_url = add_query_arg( $edit_url = add_query_arg(

View File

@ -13,7 +13,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '5.8-alpha-50766'; $wp_version = '5.8-alpha-50767';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.