Skip to content

Commit 26a42d2

Browse files
committed
fix: return standard hackathon detail notFound
1 parent 8d7649e commit 26a42d2

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

pages/hackathon/[id].tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,14 +81,14 @@ export const getServerSideProps = compose<{ id: string }>(
8181
cache(),
8282
errorLogger,
8383
async ({ params }) => {
84-
if (!params?.id) return { notFound: true, props: {} };
84+
if (!params?.id) return { notFound: true };
8585

8686
const activity = await new ActivityModel().getOne(params!.id);
8787
const { appId, tableIdMap } = activity.databaseSchema || {};
8888

89-
if (!appId || !tableIdMap) return { notFound: true, props: {} };
89+
if (!appId || !tableIdMap) return { notFound: true };
9090

91-
for (const key of RequiredTableKeys) if (!tableIdMap[key]) return { notFound: true, props: {} };
91+
for (const key of RequiredTableKeys) if (!tableIdMap[key]) return { notFound: true };
9292

9393
const [people, organizations, agenda, prizes, templates, projects] = await Promise.all([
9494
new PersonModel(appId, tableIdMap.Person).getAll(),

0 commit comments

Comments
 (0)