From d366821ebfd024c84cba3ef7abb34ed3d1636523 Mon Sep 17 00:00:00 2001 From: Ella <4710635+ellatrix@users.noreply.github.com> Date: Wed, 30 Oct 2024 08:02:00 +0100 Subject: [PATCH] Query block: remove incorrect selector call --- .../block-library/src/query/edit/query-content.js | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/packages/block-library/src/query/edit/query-content.js b/packages/block-library/src/query/edit/query-content.js index 8b3ff09b17934b..8c0e5d0d3bc317 100644 --- a/packages/block-library/src/query/edit/query-content.js +++ b/packages/block-library/src/query/edit/query-content.js @@ -50,16 +50,7 @@ export default function QueryContent( { const innerBlocksProps = useInnerBlocksProps( blockProps, { template: TEMPLATE, } ); - const isTemplate = useSelect( - ( select ) => { - const currentTemplate = - select( coreStore ).__experimentalGetTemplateForLink()?.type; - const isInTemplate = 'wp_template' === currentTemplate; - const isInSingularContent = postType !== undefined; - return isInTemplate && ! isInSingularContent; - }, - [ postType ] - ); + const isTemplate = postType === undefined; const { postsPerPage } = useSelect( ( select ) => { const { getSettings } = select( blockEditorStore ); const { getEntityRecord, getEntityRecordEdits, canUser } =