From c334b8b65069fa4a6333958d040dac8c01573328 Mon Sep 17 00:00:00 2001 From: Kunthawat Greethong Date: Thu, 11 Jun 2026 08:52:42 +0700 Subject: [PATCH] fix(services/[slug]): handle missing bullets/items fields in legacy data ai-consult service has data.services[i].items (not .bullets), so .map(bullets) crashed during build. Use s.bullets || s.items || [] fallback. Also data-surface defaults to 'white' when missing. --- src/pages/services/[slug].astro | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pages/services/[slug].astro b/src/pages/services/[slug].astro index 1cbcbca..c703f5f 100644 --- a/src/pages/services/[slug].astro +++ b/src/pages/services/[slug].astro @@ -256,7 +256,7 @@ const featureList = data.features || data.services || [];
{data.services.map((s: any, idx: number) => ( -
+
0{idx + 1}
@@ -264,7 +264,7 @@ const featureList = data.features || data.services || [];

{s.title}

    - {s.bullets.map((b: string) =>
  • {b}
  • )} + {(s.bullets || s.items || []).map((b: string) =>
  • {b}
  • )}