Skip to content

Commit

Permalink
Group - Fix overzealous regex when restoring inner containers (#36221)
Browse files Browse the repository at this point in the history
  • Loading branch information
davecpage authored and noisysocks committed Nov 15, 2021
1 parent bd5cb05 commit 1778240
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/block-supports/layout.php
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ function () use ( $style ) {
function gutenberg_restore_group_inner_container( $block_content, $block ) {
$tag_name = isset( $block['attrs']['tagName'] ) ? $block['attrs']['tagName'] : 'div';
$group_with_inner_container_regex = sprintf(
'/(^\s*<%1$s\b[^>]*wp-block-group(\s|")[^>]*>)(\s*<div\b[^>]*wp-block-group__inner-container(\s|")[^>]*>)((.|\S|\s)*)/',
'/(^\s*<%1$s\b[^>]*wp-block-group(\s|")[^>]*>)(\s*<div\b[^>]*wp-block-group__inner-container(\s|")[^>]*>)((.|\S|\s)*)/U',
preg_quote( $tag_name, '/' )
);
if (
Expand Down

0 comments on commit 1778240

Please sign in to comment.