mirror of
https://github.com/trafficlunar/tomodachi-share.git
synced 2026-03-28 19:23:15 +00:00
Compare commits
1 commit
3dec208e02
...
f71f8c82ae
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f71f8c82ae |
3 changed files with 797 additions and 565 deletions
14
package.json
14
package.json
|
|
@ -16,7 +16,7 @@
|
|||
"@bprogress/next": "^3.2.12",
|
||||
"@hello-pangea/dnd": "^18.0.1",
|
||||
"@prisma/client": "^6.19.2",
|
||||
"@sentry/nextjs": "^10.40.0",
|
||||
"@sentry/nextjs": "^10.39.0",
|
||||
"bit-buffer": "^0.3.0",
|
||||
"canvas-confetti": "^1.9.4",
|
||||
"dayjs": "^1.11.19",
|
||||
|
|
@ -35,24 +35,24 @@
|
|||
"seedrandom": "^3.0.5",
|
||||
"sharp": "^0.34.5",
|
||||
"sjcl-with-all": "1.0.8",
|
||||
"swr": "^2.4.1",
|
||||
"swr": "^2.4.0",
|
||||
"zod": "^4.3.6"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@eslint/eslintrc": "^3.3.4",
|
||||
"@eslint/eslintrc": "^3.3.3",
|
||||
"@iconify/react": "^6.0.2",
|
||||
"@tailwindcss/postcss": "^4.2.1",
|
||||
"@tailwindcss/postcss": "^4.2.0",
|
||||
"@types/canvas-confetti": "^1.9.0",
|
||||
"@types/node": "^25.3.3",
|
||||
"@types/node": "^25.3.0",
|
||||
"@types/react": "^19.2.14",
|
||||
"@types/react-dom": "^19.2.3",
|
||||
"@types/seedrandom": "^3.0.8",
|
||||
"@types/sjcl": "^1.0.34",
|
||||
"eslint": "^10.0.2",
|
||||
"eslint": "^10.0.1",
|
||||
"eslint-config-next": "16.1.6",
|
||||
"prisma": "^6.19.2",
|
||||
"schema-dts": "^1.1.5",
|
||||
"tailwindcss": "^4.2.1",
|
||||
"tailwindcss": "^4.2.0",
|
||||
"typescript": "^5.9.3"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
1316
pnpm-lock.yaml
1316
pnpm-lock.yaml
File diff suppressed because it is too large
Load diff
|
|
@ -19,26 +19,26 @@ export const metadata: Metadata = {
|
|||
};
|
||||
|
||||
export default async function SubmitPage() {
|
||||
const session = await auth();
|
||||
// const session = await auth();
|
||||
|
||||
if (!session) redirect("/login");
|
||||
if (!session.user.username) redirect("/create-username");
|
||||
const activePunishment = await prisma.punishment.findFirst({
|
||||
where: {
|
||||
userId: Number(session?.user.id),
|
||||
returned: false,
|
||||
},
|
||||
});
|
||||
if (activePunishment) redirect("/off-the-island");
|
||||
// if (!session) redirect("/login");
|
||||
// if (!session.user.username) redirect("/create-username");
|
||||
// const activePunishment = await prisma.punishment.findFirst({
|
||||
// where: {
|
||||
// userId: Number(session?.user.id),
|
||||
// returned: false,
|
||||
// },
|
||||
// });
|
||||
// if (activePunishment) redirect("/off-the-island");
|
||||
|
||||
// Check if submissions are disabled
|
||||
let value: boolean | null = true;
|
||||
try {
|
||||
const response = await fetch(`${process.env.NEXT_PUBLIC_BASE_URL}/api/admin/can-submit`);
|
||||
value = await response.json();
|
||||
} catch (error) {
|
||||
return <p>An error occurred!</p>;
|
||||
}
|
||||
// try {
|
||||
// const response = await fetch(`${process.env.NEXT_PUBLIC_BASE_URL}/api/admin/can-submit`);
|
||||
// value = await response.json();
|
||||
// } catch (error) {
|
||||
// return <p>An error occurred!</p>;
|
||||
// }
|
||||
|
||||
if (!value)
|
||||
return (
|
||||
|
|
|
|||
Loading…
Reference in a new issue