Merged in fix/book-453-linkconnection (pull request #2972)

fix(BOOK-453): avoid linkConnection invalid

* fix(BOOK-453): avoid linkConnection invalid

* test

* test

* test

* Merge master
This commit is contained in:
Linus Flood
2025-10-22 12:39:17 +00:00
parent 03f17acbbe
commit acdc3dcec1
17 changed files with 79 additions and 46 deletions

View File

@@ -97,7 +97,7 @@ export function getConnections({ collection_page }: CollectionPageRefs) {
switch (block.__typename) {
case CollectionPageEnum.ContentStack.blocks.Shortcuts: {
if (block.shortcuts.shortcuts.length) {
connections.push(...block.shortcuts.shortcuts)
connections.push(...block.shortcuts.shortcuts.filter((c) => !!c))
}
break
}
@@ -109,7 +109,7 @@ export function getConnections({ collection_page }: CollectionPageRefs) {
}
case CollectionPageEnum.ContentStack.blocks.UspGrid: {
if (block.usp_grid.length) {
connections.push(...block.usp_grid)
connections.push(...block.usp_grid.filter((c) => !!c))
}
}
}