Merged in fix/LOY-400-make-contentstack-data-optional (pull request #3266)

fix(LOY-400): made contentstack data optional so the whole page does not crash if it's empty.

* fix(LOY-400): made contentstack data optional so the whole page does not crash if it's empty.

* Merged in fix/LOY-400-make-contentstack-data-optional-2 (pull request #3269)

Fix/LOY-400 make contentstack data optional 2

* Test

* .

* Correct ref tag

* refactor

* Correct key

* fix(LOY-400): cleaned up


Approved-by: Linus Flood
Approved-by: Matilda Landström
This commit is contained in:
Emma Zettervall
2025-12-02 08:08:12 +00:00
parent 95473927f2
commit 34526bbaf1
5 changed files with 95 additions and 68 deletions

View File

@@ -67,7 +67,11 @@ export function UsePointsModal({
const bookLink = `${pathname}?${searchParams}`
const [items] = contentData.all_usepointsmodal.items
const items = contentData?.all_usepointsmodal?.items?.[0]
if (!items) {
return null
}
const linkListItems = items.link_group.map((link) => ({
text: link.text,