Skip to content

Commit

Permalink
fix build error
Browse files Browse the repository at this point in the history
  • Loading branch information
SivaramPg committed Aug 25, 2024
1 parent 4a2f0c4 commit 8a34475
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/app/[category]/[slug]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ export async function generateStaticParams() {
category.isFile() &&
!["all.json", ".DS_Store", "root.json"].includes(category.name)
) {
const [categoryName, slug] = category.name.split("/")
const categoryName = category.path.split("/").at(-1)

slugs.push({
category: categoryName,
slug: slug.split(".")[0],
category: categoryName ?? "",
slug: category.name.split(".")[0],
})
}
}
Expand Down

0 comments on commit 8a34475

Please sign in to comment.