User registration.

This commit is contained in:
Daniel
2023-01-31 15:06:56 +03:30
parent 4cd0e8799c
commit 882bbd64d1
12 changed files with 231 additions and 11 deletions
+11
View File
@@ -0,0 +1,11 @@
import { PrismaClient } from "@prisma/client";
const globalForPrisma = global as unknown as { prisma: PrismaClient };
export const prisma =
globalForPrisma.prisma ||
new PrismaClient({
log: ["query"],
});
if (process.env.NODE_ENV !== "production") globalForPrisma.prisma = prisma;