Menus: Simplify the test for `wp_update_nav_menu_item()` with special characters in category name.

The `menu-item-title` value is saved as a `post_title` property, so the resulting property can be checked directly, without a callback.

Follow-up to [48416].

See #48011.
Built from https://develop.svn.wordpress.org/trunk@48439


git-svn-id: http://core.svn.wordpress.org/trunk@48208 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2020-07-11 21:48:04 +00:00
parent f718b4b6ec
commit b640c0692e
2 changed files with 2 additions and 2 deletions

View File

@ -492,7 +492,7 @@ function wp_update_nav_menu_item( $menu_id = 0, $menu_item_db_id = 0, $menu_item
}
}
if ( wp_unslash( $args['menu-item-title'] ) == wp_specialchars_decode( $original_title ) ) {
if ( wp_unslash( $args['menu-item-title'] ) === wp_specialchars_decode( $original_title ) ) {
$args['menu-item-title'] = '';
}

View File

@ -13,7 +13,7 @@
*
* @global string $wp_version
*/
$wp_version = '5.5-beta1-48438';
$wp_version = '5.5-beta1-48439';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.