diff --git a/app/invite/[code]/actions.ts b/app/invite/[code]/actions.ts index 06e0c77..5967b96 100644 --- a/app/invite/[code]/actions.ts +++ b/app/invite/[code]/actions.ts @@ -58,6 +58,11 @@ export async function acceptInvite( userId, collectionId: invite.collectionId, accessLevel: invite.accessLevel, + // TODO: find a better way to enforce a specific testsolver type + ...(invite.collection.cid === "topsoj" && { + testsolverType: "Serious", + seriousTestsolverStartedAt: invite.collection.createdAt, + }), }, }); diff --git a/components/sidebar.tsx b/components/sidebar.tsx index 284b899..8196a87 100644 --- a/components/sidebar.tsx +++ b/components/sidebar.tsx @@ -25,6 +25,11 @@ export default function Sidebar({ children }: { children: React.ReactNode }) { label: "OTIS Mock AIME", active: pathname !== null && pathname.startsWith("/c/otis-mock-aime"), }, + { + href: "/c/topsoj", + label: "TopsOJ", + active: pathname !== null && pathname.startsWith("/c/topsoj"), + }, ]; return (