import { PrismaClient } from '@prisma/client' ; /**
 * Instantiate prisma client for Next.js:
 * https://www.prisma.io/docs/support/help-articles/nextjs-prisma-client-dev-practices#solution
 */ declare global { var prisma ; } export const prisma = global . prisma || new PrismaClient ( { log : [ 'query' ] , } ) ; if ( process . env . NODE_ENV !== 'production' ) { global . prisma = prisma ; } export async function disconnect ( ) { await prisma . $disconnect ( ) ; return true ; } export async function connect ( ) { await prisma . $connect ( ) ; return true ; }