update
Some checks failed
Deploy to SFTP Server / build (push) Has been cancelled

This commit is contained in:
Max Richter
2025-10-04 14:07:46 +02:00
parent a1b8eb22e5
commit 61251e2c85
2 changed files with 3 additions and 3 deletions

View File

@@ -11,7 +11,7 @@ const collection = "resources/Recipes";
export async function getStaticPaths() {
const recipes = await memorium.listResource("Recipes");
const paths = recipes.content.filter(res =>res.content).map((recipe: any) => {
const paths = recipes.content?.filter(res =>res.content).map((recipe: any) => {
return {
params: {
recipeName: recipe.name.replace(/\.md$/, ""),
@@ -19,7 +19,7 @@ export async function getStaticPaths() {
};
});
return paths;
return paths ?? [];
}
const recipeResponse = await memorium.listResource(

View File

@@ -9,7 +9,7 @@ const recipes = await memorium.listResource("Recipes");
<Layout title="Max Richter">
{
recipes.content
.filter((res) => res.content)
?.filter((res) => res.content)
.map((recipe: any) => (
<HeroCard
post={{