fix: use hook data to create a new DB instance
This commit is contained in:
parent
5c01942948
commit
4fb912cbf9
|
@ -5,7 +5,7 @@ export class Postgres {
|
|||
client: pg.PoolClient | null = null;
|
||||
public static async new(pool: pg.Pool) {
|
||||
const pg = new Postgres();
|
||||
pg.client = await getConnection().connect();
|
||||
pg.client = await pool.connect();
|
||||
return pg;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user