From fdcb34fad386ff080116b14c5d07559bc2cccf81 Mon Sep 17 00:00:00 2001 From: gziolo Date: Tue, 19 Jul 2022 13:24:12 +0000 Subject: [PATCH] Editor: Fix `register_block_type` does not recognise `ancestor` block setting When registering block through PHP, using `register_block_type` function, newly introduced `ancestor` block setting in `block.json` was not recognised. It worked though, when block is registered from JavaScript. Props lovor, annezazu. Fixes #56184. Built from https://develop.svn.wordpress.org/trunk@53718 git-svn-id: http://core.svn.wordpress.org/trunk@53277 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/blocks.php | 1 + wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/wp-includes/blocks.php b/wp-includes/blocks.php index 9df70abaf4..a2fd54cf31 100644 --- a/wp-includes/blocks.php +++ b/wp-includes/blocks.php @@ -286,6 +286,7 @@ function register_block_type_from_metadata( $file_or_folder, $args = array() ) { 'title' => 'title', 'category' => 'category', 'parent' => 'parent', + 'ancestor' => 'ancestor', 'icon' => 'icon', 'description' => 'description', 'keywords' => 'keywords', diff --git a/wp-includes/version.php b/wp-includes/version.php index f89ba0c6a5..9402535d0a 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.1-alpha-53717'; +$wp_version = '6.1-alpha-53718'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.