mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-30 09:58:12 +00:00
Initial commit of edr-passenger-api alpha version
This commit is contained in:
8
apps/edr-passenger-api/src/common/prisma.service.ts
Normal file
8
apps/edr-passenger-api/src/common/prisma.service.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
import { Injectable, OnModuleInit, OnModuleDestroy } from '@nestjs/common';
|
||||
import { PrismaClient } from '@prisma/client';
|
||||
|
||||
@Injectable()
|
||||
export class PrismaService extends PrismaClient implements OnModuleInit, OnModuleDestroy {
|
||||
async onModuleInit() { await this.$connect(); }
|
||||
async onModuleDestroy() { await this.$disconnect(); }
|
||||
}
|
||||
Reference in New Issue
Block a user