Changeset 56677
- Timestamp:
- 09/25/2023 11:46:08 AM (13 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/blocks.php
r56674 r56677 750 750 */ 751 751 function get_hooked_blocks( $name, $relative_position = '' ) { 752 $block_types = WP_Block_Type_Registry::get_instance()->get_all_registered();752 $block_types = WP_Block_Type_Registry::get_instance()->get_all_registered(); 753 753 $hooked_blocks = array(); 754 754 foreach ( $block_types as $block_type ) { 755 if ( ! property_exists( $block_type, 'block_hooks') || ! is_array( $block_type->block_hooks ) ) {755 if ( ! ( $block_type instanceof WP_Block_Type ) || ! is_array( $block_type->block_hooks ) ) { 756 756 continue; 757 757 }
Note: See TracChangeset
for help on using the changeset viewer.