From 8fe19ad153eb11a1f2ccdc48560039cd09fec8fd Mon Sep 17 00:00:00 2001 From: Imam Fahrur Rofi Date: Thu, 11 Jan 2024 00:31:20 +0700 Subject: [PATCH] fix pg pool type error --- src/postgres/drizzle.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/postgres/drizzle.ts b/src/postgres/drizzle.ts index 8e69ae2..ef7e05a 100644 --- a/src/postgres/drizzle.ts +++ b/src/postgres/drizzle.ts @@ -1,5 +1,5 @@ import { drizzle } from 'drizzle-orm/node-postgres'; -import { Pool } from 'pg'; +import pg from 'pg'; import { postgresConfig } from '../config'; import { eq } from 'drizzle-orm'; import { serial, text, pgTable, timestamp } from 'drizzle-orm/pg-core'; @@ -21,7 +21,7 @@ if (max) { Object.assign(config, { max }); } -const pool = new Pool(config); +const pool = new pg.Pool(config); const db = drizzle(pool);