From 3ef024f14982556367cdb3b1b19b5cc580e6b819 Mon Sep 17 00:00:00 2001 From: prototypa Date: Mon, 7 Aug 2023 08:21:02 -0400 Subject: [PATCH] Allow child posts (or sub posts) --- src/utils/blog.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/utils/blog.ts b/src/utils/blog.ts index c310966..5be45da 100644 --- a/src/utils/blog.ts +++ b/src/utils/blog.ts @@ -56,7 +56,7 @@ const getNormalizedPost = async (post: CollectionEntry<'post'>): Promise = metadata = {}, } = data; - const slug = cleanSlug(rawSlug.split('/').pop()); + const slug = cleanSlug(rawSlug); // cleanSlug(rawSlug.split('/').pop()); const publishDate = new Date(rawPublishDate); const updateDate = rawUpdateDate ? new Date(rawUpdateDate) : undefined; const category = rawCategory ? cleanSlug(rawCategory) : undefined;