From 6d16bbc08879a4c8df997f3aece6bec3d83c9be0 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Tue, 30 May 2023 14:13:22 +0000 Subject: [PATCH] Docs: Add a `@since` tag for the `pre_wp_setup_nav_menu_item` filter. Includes moving the unit test next to the other `wp_setup_nav_menu_item()` tests and using the `MockAction` class to confirm that the filter runs. Follow-up to [55867]. Props TobiasBg. Fixes #56577. Built from https://develop.svn.wordpress.org/trunk@55868 git-svn-id: http://core.svn.wordpress.org/trunk@55380 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/nav-menu.php | 6 ++++-- wp-includes/version.php | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/wp-includes/nav-menu.php b/wp-includes/nav-menu.php index cb49f2b38c..229ba8496b 100644 --- a/wp-includes/nav-menu.php +++ b/wp-includes/nav-menu.php @@ -822,10 +822,12 @@ function update_menu_item_cache( $menu_items ) { function wp_setup_nav_menu_item( $menu_item ) { /** - * Short-circuit the wp_setup_nav_menu_item() output. + * Filters whether to short-circuit the wp_setup_nav_menu_item() output. * * Returning a non-null value from the filter will short-circuit wp_setup_nav_menu_item(), - * and return that value. + * returning that value instead. + * + * @since 6.3.0 * * @param object|null $modified_menu_item Modified menu item. Default null. * @param object $menu_item The menu item to modify. diff --git a/wp-includes/version.php b/wp-includes/version.php index ddd8e21f83..61ae0aae76 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.3-alpha-55867'; +$wp_version = '6.3-alpha-55868'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.