Commit 639eb99b authored by ThinhNC's avatar ThinhNC

refactor: prisma.client

parent afae4e62
import { PrismaClient } from '@prisma/client';
import databaseConfig from '../config/database.config';
export const prisma = new PrismaClient({
datasources: {
db: {
url: databaseConfig.url,
},
},
log: process.env.NODE_ENV === 'development'
? ['query', 'error', 'warn']
: ['error', 'warn'],
});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment