Skip to content

Commit

Permalink
Fix nested block inserter
Browse files Browse the repository at this point in the history
  • Loading branch information
ellatrix committed Jan 9, 2020
1 parent 5aae9ca commit 4c12937
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/block-editor/src/components/inserter/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ export default compose( [
__experimentalGetAllowedBlocks,
} = select( 'core/block-editor' );

rootClientId = rootClientId || getBlockRootClientId( clientId );
rootClientId = rootClientId || getBlockRootClientId( clientId ) || undefined;

const allowedBlocks = __experimentalGetAllowedBlocks( rootClientId );

Expand All @@ -157,6 +157,7 @@ export default compose( [
hasSingleBlockType,
blockTitle: allowedBlockType ? allowedBlockType.title : '',
allowedBlockType,
rootClientId,
};
} ),
withDispatch( ( dispatch, ownProps, { select } ) => {
Expand Down

0 comments on commit 4c12937

Please sign in to comment.