diff --git a/apps/deploy-web/src/pages/templates/[templateId]/index.tsx b/apps/deploy-web/src/pages/templates/[templateId]/index.tsx index 8d5f0d5b9..1dc6eddf2 100644 --- a/apps/deploy-web/src/pages/templates/[templateId]/index.tsx +++ b/apps/deploy-web/src/pages/templates/[templateId]/index.tsx @@ -24,6 +24,12 @@ export async function getServerSideProps({ params }) { const templates = categories.flatMap(x => x.templates); const template = templates.find(x => x.id === params?.templateId); + if (!template) { + return { + notFound: true + }; + } + return { props: { templateId: params?.templateId,