Skip to content

Commit

Permalink
Rename function call and call using string in filter
Browse files Browse the repository at this point in the history
  • Loading branch information
artemiomorales committed Jan 16, 2024
1 parent 9c8bf55 commit e6473a7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/experimental/blocks.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,15 +89,15 @@ function wp_enqueue_block_view_script( $block_name, $args ) {

require_once __DIR__ . '/block-bindings/index.php';

if ( ! function_exists( 'process_block_bindings' ) ) {
if ( ! function_exists( 'gutenberg_process_block_bindings' ) ) {
/**
* Process the block bindings attribute.
*
* @param string $block_content Block Content.
* @param array $block Block attributes.
* @param WP_Block $block_instance The block instance.
*/
function process_block_bindings( $block_content, $block, $block_instance ) {
function gutenberg_process_block_bindings( $block_content, $block, $block_instance ) {

// Allowed blocks that support block bindings.
// TODO: Look for a mechanism to opt-in for this. Maybe adding a property to block attributes?
Expand Down Expand Up @@ -164,5 +164,5 @@ function process_block_bindings( $block_content, $block, $block_instance ) {
}
}

add_filter( 'render_block', process_block_bindings, 20, 3 );
add_filter( 'render_block', 'gutenberg_process_block_bindings', 20, 3 );
}

0 comments on commit e6473a7

Please sign in to comment.