test(backend): fix unit tests for media magic validation, slow query logger, and support chat specs
Deploy Canina / deploy (push) Successful in 41s

This commit is contained in:
devops committed 2026-10-18 15:40:03 +00:00
1 parent dda1caf3e0
commit 7f2f638f38
8 files changed
+42 -23

No files matched your search

+3 -1
View File
@@ -24,13 +24,15 @@ export class PrismaService
await this.$connect();
// BE-07: Slow query logging interceptor (> 300ms)
(this as any).$on("query", (e: any) => {
if (typeof (this as any).$on === "function") {
(this as any).$on("query", (e: any) => {
if (e.duration >= 300) {
this.logger.warn(
`[SlowQueryAlert] Duration: ${e.duration}ms | Target: ${e.target} | Query: ${e.query.substring(0, 300)}...`,
);
}
});
}
await this.ensureTablesExist();
}