Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Commit

Permalink
try now
Browse files Browse the repository at this point in the history
  • Loading branch information
gigitux committed Apr 17, 2023
1 parent 8206df6 commit 373f311
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/Templates/SingleProductTemplateCompatibility.php
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,9 @@ function( $carry, $item ) {
* @return array Wrapped template content inside a div.
*/
private static function wrap_single_product_template( $template_content ) {
$parsed_blocks = parse_blocks( $template_content );
$parsed_blocks = parse_blocks( $template_content );
do_action( 'qm/debug', $parsed_blocks );

$grouped_blocks = self::group_blocks( $parsed_blocks );

$single_product_template_blocks = array( 'woocommerce/product-image-gallery', 'woocommerce/product-details', 'woocommerce/add-to-cart-form', 'woocommerce/product-meta', 'woocommerce/product-price', 'woocommerce/breadcrumbs' );
Expand Down Expand Up @@ -433,7 +435,7 @@ function( $carry, $block ) {
$carry[] = array( $block );
return $carry;
}
if ( empty( $block['blockName'] ) && empty( $block['innerContent'] ) ) {
if ( empty( $block['blockName'] ) && '' === $block['innerHTML'] ) {
return $carry;
}
$last_element_index = count( $carry ) - 1;
Expand Down

0 comments on commit 373f311

Please sign in to comment.