Skip to content

Commit

Permalink
Be explicit about the check
Browse files Browse the repository at this point in the history
  • Loading branch information
oandregal committed Oct 18, 2024
1 parent 388dd81 commit 2ec7a03
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/block-editor/src/store/selectors.js
Original file line number Diff line number Diff line change
Expand Up @@ -1595,7 +1595,7 @@ const isBlockVisibleInTheInserter = (
checkedBlocks.add( blockName );

// If parent blocks are not visible, child blocks should be hidden too.
if ( !! blockType.parent?.length ) {
if ( Array.isArray( blockType?.parent ) ) {
return blockType.parent.some(
( name ) =>
( blockName !== name &&
Expand Down

0 comments on commit 2ec7a03

Please sign in to comment.