From b4f4c2cfc111d104da11cdb3a9167de99c16d9ac Mon Sep 17 00:00:00 2001 From: George Hotelling Date: Fri, 20 Mar 2020 14:18:25 -0400 Subject: [PATCH] Fix PHP warning --- packages/block-library/src/query/index.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/block-library/src/query/index.php b/packages/block-library/src/query/index.php index 19b710c03d27d..d834ed040877d 100644 --- a/packages/block-library/src/query/index.php +++ b/packages/block-library/src/query/index.php @@ -93,9 +93,11 @@ function render_block_core_query( $attributes ) { foreach ( $blocks as $block ) { $block_data = array( 'blockName' => $block['name'], - 'attrs' => $block['attributes'], 'innerContent' => array(), ); + if ( isset( $block['attributes'])) { + $block_data['attrs'] = $block['attributes']; + } $allowed_html = wp_kses_allowed_html( 'post' ); $allowed_html['time'] = array(