diff --git a/packages/astro/src/content/utils.ts b/packages/astro/src/content/utils.ts index 3082f344f49c..f67a7ad63d5b 100644 --- a/packages/astro/src/content/utils.ts +++ b/packages/astro/src/content/utils.ts @@ -168,7 +168,7 @@ export async function getEntryDataAndImages< ): Promise<{ data: TOutputData; imageImports: Array }> { let data: TOutputData; // Legacy content collections have 'slug' removed - if (collectionConfig.type === 'content') { + if (collectionConfig.type === 'content' || (collectionConfig as any)._legacy) { const { slug, ...unvalidatedData } = entry.unvalidatedData; data = unvalidatedData as TOutputData; } else {