Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
ockham committed Aug 10, 2023
1 parent 9aa2d5c commit b1c3a45
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/experimental/auto-inserting-blocks.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ function gutenberg_auto_insert_block( $inserted_block, $relative_position, $anch
}

function gutenberg_add_auto_insert_field_to_block_type_controller( $inserted_block, $position, $anchor_block ) {
return function( $response, $block_type ) use ( $inserted_block, $position, $anchor_block ){
return function( $response, $block_type ) use ( $inserted_block, $position, $anchor_block ) {
if ( $block_type->name !== $inserted_block ) {
return $response;
}
Expand All @@ -74,7 +74,7 @@ function gutenberg_add_auto_insert_field_to_block_type_controller( $inserted_blo
if ( ! isset( $data['auto_insert'] ) ) {
$data['auto_insert'] = array();
}
$data['auto_insert'][ $anchor_block ] = $position ;
$data['auto_insert'][ $anchor_block ] = $position;
$response->set_data( $data );
return $response;
};
Expand Down Expand Up @@ -289,7 +289,7 @@ function gutenberg_register_auto_insert_rest_field() {
'block-type',
'auto_insert',
array(
'schema' => array(
'schema' => array(
'description' => __( 'Auto Insert.', 'default' ),
'type' => 'object',
),
Expand Down

0 comments on commit b1c3a45

Please sign in to comment.