We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a1cba58 commit 43eb4a5Copy full SHA for 43eb4a5
src/lib/utils.ts
@@ -12,8 +12,14 @@ const groupBlockContent = (blockMap: BlockMap) => {
12
let index = -1
13
14
Object.keys(blockMap).forEach((id) => {
15
- blockMap[id].value.content?.forEach((blockId) => {
16
- const blockType = blockMap[blockId]?.value?.type
+ const blockValue = blockMap[id]?.value
+ if (!blockValue?.content) return
17
+
18
+ blockValue.content.forEach((blockId) => {
19
+ const nestedBlock = blockMap[blockId]?.value
20
+ if (!nestedBlock) return
21
22
+ const blockType = nestedBlock.type
23
24
if (blockType && blockType !== lastType) {
25
index++
0 commit comments