From 3d86a763a6aaa7d5c025a7c36c5e57e44d0e92e8 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Tue, 31 Oct 2023 12:56:16 +0000 Subject: [PATCH] Docs: Update some reusable block references to synced patterns. In WordPress 6.3, [https://wordpress.org/documentation/article/reusable-blocks/ Reusable Blocks were renamed to Patterns]. A synced pattern will behave in exactly the same way as a reusable block. This commit updates some references in DocBlocks and inline comments to use the new name. Follow-up to [56030]. Props benjaminknox, oglekler, hellofromTonya, marybaum, nicolefurlan. Fixes #59388. git-svn-id: https://develop.svn.wordpress.org/trunk@57032 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/blocks.php | 3 +- .../class-wp-rest-blocks-controller.php | 30 +++++++++---------- tests/phpunit/tests/blocks/renderReusable.php | 4 +-- .../tests/rest-api/rest-blocks-controller.php | 2 +- 4 files changed, 20 insertions(+), 19 deletions(-) diff --git a/src/wp-includes/blocks.php b/src/wp-includes/blocks.php index ce5853d32d..1edc0762d3 100644 --- a/src/wp-includes/blocks.php +++ b/src/wp-includes/blocks.php @@ -659,7 +659,8 @@ function has_blocks( $post = null ) { * * This test optimizes for performance rather than strict accuracy, detecting * whether the block type exists but not validating its structure and not checking - * reusable blocks. For strict accuracy, you should use the block parser on post content. + * synced patterns (formerly called reusable blocks). For strict accuracy, + * you should use the block parser on post content. * * @since 5.0.0 * diff --git a/src/wp-includes/rest-api/endpoints/class-wp-rest-blocks-controller.php b/src/wp-includes/rest-api/endpoints/class-wp-rest-blocks-controller.php index 305647451b..7999b02309 100644 --- a/src/wp-includes/rest-api/endpoints/class-wp-rest-blocks-controller.php +++ b/src/wp-includes/rest-api/endpoints/class-wp-rest-blocks-controller.php @@ -1,6 +1,6 @@