From 07c035cebb4c13563a6e43e7726c5e56d6cff9cb Mon Sep 17 00:00:00 2001 From: Alexandre Lara Date: Fri, 16 Jun 2023 17:06:01 -0300 Subject: [PATCH] Fix PropType warning and error when adding All Reviews block to Editor --- assets/js/blocks/reviews/all-reviews/block.tsx | 2 +- assets/js/blocks/reviews/editor-container-block.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/assets/js/blocks/reviews/all-reviews/block.tsx b/assets/js/blocks/reviews/all-reviews/block.tsx index 06d89e890f5..e7da183926c 100644 --- a/assets/js/blocks/reviews/all-reviews/block.tsx +++ b/assets/js/blocks/reviews/all-reviews/block.tsx @@ -75,7 +75,7 @@ const AllReviewsEditor = ( { /> } name={ __( 'All Reviews', 'woo-gutenberg-products-block' ) } - noReviewsPlaceholder={ NoReviewsPlaceholder() } + noReviewsPlaceholder={ NoReviewsPlaceholder } /> ); diff --git a/assets/js/blocks/reviews/editor-container-block.js b/assets/js/blocks/reviews/editor-container-block.js index 54491b75e8d..1d1c0c579b3 100644 --- a/assets/js/blocks/reviews/editor-container-block.js +++ b/assets/js/blocks/reviews/editor-container-block.js @@ -74,7 +74,7 @@ EditorContainerBlock.propTypes = { attributes: PropTypes.object.isRequired, icon: PropTypes.node.isRequired, name: PropTypes.string.isRequired, - noReviewsPlaceholder: PropTypes.element.isRequired, + noReviewsPlaceholder: PropTypes.elementType.isRequired, className: PropTypes.string, };