diff --git a/workspaces/cms-scripts/src/index.ts b/workspaces/cms-scripts/src/index.ts index 6f07c48d3a7..d97116e4e24 100644 --- a/workspaces/cms-scripts/src/index.ts +++ b/workspaces/cms-scripts/src/index.ts @@ -225,10 +225,12 @@ for (const data of roadmapPosts.filenameMap.values()) { } for (const data of announcements.filenameMap.values()) { - await write( - `public/data/announcements/${data.locale}/${data.slug}.json`, - data -); + if (!!data) { + await write( + `public/data/announcements/${data.locale}/${data.slug}.json`, + data + ); + } } for (const locale of locales) {