github-actions[bot] commited on
Commit ·
2a7936b
1
Parent(s): 5a8ac33
Deploy Backend from GitHub Actions Commit: 0a3d2ded56380e531280e18b237dea9e5bdac0c3
Browse files
src/database/prisma.service.ts
CHANGED
|
@@ -195,7 +195,11 @@ export class PrismaService
|
|
| 195 |
client.$use((params, next) => this.queryLimiter.run(() => next(params)));
|
| 196 |
}
|
| 197 |
|
| 198 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 199 |
try {
|
| 200 |
await this.$connect();
|
| 201 |
this.logger.log("Successfully connected to database.");
|
|
|
|
| 195 |
client.$use((params, next) => this.queryLimiter.run(() => next(params)));
|
| 196 |
}
|
| 197 |
|
| 198 |
+
onModuleInit() {
|
| 199 |
+
void this.connectInBackground();
|
| 200 |
+
}
|
| 201 |
+
|
| 202 |
+
private async connectInBackground() {
|
| 203 |
try {
|
| 204 |
await this.$connect();
|
| 205 |
this.logger.log("Successfully connected to database.");
|