fix: change optional to nullable in validation
This commit is contained in:
@@ -80,8 +80,7 @@ export const loyaltyPageQueryRouter = router({
|
||||
...card,
|
||||
link: card.referenceConnection.totalCount
|
||||
? {
|
||||
href: card.referenceConnection.edges[0].node
|
||||
.url,
|
||||
href: `/${card.referenceConnection.edges[0].node.system.locale}${card.referenceConnection.edges[0].node.url}`,
|
||||
title: card.cta_text || _("Read more"),
|
||||
}
|
||||
: undefined,
|
||||
@@ -97,8 +96,7 @@ export const loyaltyPageQueryRouter = router({
|
||||
link: block.dynamic_content.link.pageConnection.totalCount
|
||||
? {
|
||||
text: block.dynamic_content.link.text,
|
||||
href: block.dynamic_content.link.pageConnection
|
||||
.edges[0].node.url,
|
||||
href: `/${block.dynamic_content.link.pageConnection.edges[0].node.system.locale}${block.dynamic_content.link.pageConnection.edges[0].node.url}`,
|
||||
title:
|
||||
block.dynamic_content.link.pageConnection.edges[0]
|
||||
.node.title,
|
||||
|
||||
Reference in New Issue
Block a user