plugin updates

This commit is contained in:
Tony Volpe
2024-11-15 13:53:04 -05:00
parent 1293d604ca
commit 0238f0c4ca
2009 changed files with 163492 additions and 89543 deletions

View File

@@ -5,6 +5,11 @@
* @package WordPress
*/
// Don't load directly.
if ( ! defined( 'ABSPATH' ) ) {
die( '-1' );
}
define( 'BLOCKS_PATH', ABSPATH . WPINC . '/blocks/' );
// Include files required for core blocks registration.
@@ -20,11 +25,9 @@ require BLOCKS_PATH . 'require-dynamic-blocks.php';
* avoids unnecessary logic and filesystem lookups in the other function.
*
* @since 6.3.0
*
* @global string $wp_version The WordPress version string.
*/
function register_core_block_style_handles() {
global $wp_version;
$wp_version = wp_get_wp_version();
if ( ! wp_should_load_separate_core_block_assets() ) {
return;
@@ -155,3 +158,20 @@ function register_core_block_types_from_metadata() {
}
}
add_action( 'init', 'register_core_block_types_from_metadata' );
/**
* Registers the core block metadata collection.
*
* This function is hooked into the 'init' action with a priority of 9,
* ensuring that the core block metadata is registered before the regular
* block initialization that happens at priority 10.
*
* @since 6.7.0
*/
function wp_register_core_block_metadata_collection() {
wp_register_block_metadata_collection(
BLOCKS_PATH,
BLOCKS_PATH . 'blocks-json.php'
);
}
add_action( 'init', 'wp_register_core_block_metadata_collection', 9 );