Skip to content

Commit 1131507

Browse files
author
Mitchell Amihod
committed
Add type
1 parent f68c909 commit 1131507

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

content/recipes/prisma.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ When setting up your NestJS application, you'll want to abstract away the Prisma
247247
Inside the `src` directory, create a new file called `prisma.service.ts` and add the following code to it:
248248

249249
```typescript
250-
import { Injectable, OnModuleInit, OnModuleDestroy } from '@nestjs/common';
250+
import { INestApplication, Injectable, OnModuleInit, OnModuleDestroy } from '@nestjs/common';
251251
import { PrismaClient } from '@prisma/client';
252252

253253
@Injectable()
@@ -258,7 +258,7 @@ export class PrismaService extends PrismaClient
258258
await this.$connect();
259259
}
260260

261-
async enableShutdownHooks(app) {
261+
async enableShutdownHooks(app: INestApplication) {
262262
this.$on('beforeExit', async () => {
263263
await app.close();
264264
});

0 commit comments

Comments
 (0)