Skip to content

Commit 8d8f7ce

Browse files
authored
Merge pull request #588 from devforth/feature/AdminForth/1492/image
fix: switch from Client to Pool for PostgreSQL connection management
2 parents f56f836 + a6a3deb commit 8d8f7ce

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

adminforth/dataConnectors/postgres.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@ import AdminForthBaseConnector from './baseConnector.js';
55
import pkg from 'pg';
66
import { afLogger, dbLogger } from '../modules/logger.js';
77

8-
const { Client } = pkg;
8+
const { Pool } = pkg;
99

1010

1111
class PostgresConnector extends AdminForthBaseConnector implements IAdminForthDataSourceConnector {
1212

1313
async setupClient(url: string): Promise<void> {
14-
this.client = new Client({
14+
this.client = new Pool({
1515
connectionString: url
1616
});
1717
try {

0 commit comments

Comments
 (0)