Skip to content

Commit

Permalink
Coding Standards: Use strict comparison in `wp-includes/class-wp-cust…
Browse files Browse the repository at this point in the history
…omize-nav-menus.php`.

See #52627.

git-svn-id: https://develop.svn.wordpress.org/trunk@51047 602fd350-edb4-49c9-b593-d223f7449a82
  • Loading branch information
SergeyBiryukov committed May 30, 2021
1 parent 59e55af commit b06ec69
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/wp-includes/class-wp-customize-nav-menus.php
Expand Up @@ -488,6 +488,7 @@ public function enqueue_scripts() {
$temp_nav_menu_item_setting = new WP_Customize_Nav_Menu_Item_Setting( $this->manager, 'nav_menu_item[-1]' );

$num_locations = count( get_registered_nav_menus() );

if ( 1 === $num_locations ) {
$locations_description = __( 'Your theme can display menus in one location.' );
} else {
Expand Down Expand Up @@ -679,7 +680,8 @@ public function customize_register() {
// Menu locations.
$locations = get_registered_nav_menus();
$num_locations = count( $locations );
if ( 1 == $num_locations ) {

if ( 1 === $num_locations ) {
$description = '<p>' . __( 'Your theme can display menus in one location. Select which menu you would like to use.' ) . '</p>';
} else {
/* translators: %s: Number of menu locations. */
Expand Down

0 comments on commit b06ec69

Please sign in to comment.