diff --git a/apps/backend/src/modules/prisma/prisma.service.ts b/apps/backend/src/modules/prisma/prisma.service.ts index ce53bdb..fcee9ec 100644 --- a/apps/backend/src/modules/prisma/prisma.service.ts +++ b/apps/backend/src/modules/prisma/prisma.service.ts @@ -22,11 +22,20 @@ export class PrismaService async getExtensions(): Promise< { - oid: string | number; + oid: number; extname: string; }[] > { - return await this.$queryRaw`SELECT * FROM pg_extension`; + try { + return await this.$queryRaw` + SELECT oid::integer as oid, extname + FROM pg_extension + `; + } catch (error) { + throw new Error( + `Failed to fetch database extensions: ${error.message}`, + ); + } } async getExtensionNames(): Promise {