From 42b6637248921bde48f918a414d47c995da8281e Mon Sep 17 00:00:00 2001 From: Mathias Oterhals Myklebust Date: Fri, 20 Sep 2024 14:51:14 +0200 Subject: [PATCH] feat(seo): include non-pageBuilder documents in seo fetching --- studio/lib/queries/page.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/studio/lib/queries/page.ts b/studio/lib/queries/page.ts index d25aa3e05..75a300223 100644 --- a/studio/lib/queries/page.ts +++ b/studio/lib/queries/page.ts @@ -77,7 +77,7 @@ export const SLUG_QUERY = groq` `; export const SEO_SLUG_QUERY = groq` - *[_type == "pageBuilder" && slug.current == $slug][0]{ + *[defined(seo) && slug.current == $slug][0]{ "title": seo.seoTitle, "description": seo.seoDescription, "imageUrl": seo.seoImage.asset->url