@prisma/adapter-pg 7.6.0-dev.1 → 7.6.0-dev.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +3 -0
- package/dist/index.mjs +3 -0
- package/package.json +3 -3
package/dist/index.d.mts
CHANGED
|
@@ -39,7 +39,7 @@ export declare class PrismaPg implements SqlMigrationAwareDriverAdapterFactory {
|
|
|
39
39
|
readonly adapterName: string;
|
|
40
40
|
private readonly config;
|
|
41
41
|
private externalPool;
|
|
42
|
-
constructor(poolOrConfig: pg.Pool | pg.PoolConfig, options?: PrismaPgOptions | undefined);
|
|
42
|
+
constructor(poolOrConfig: pg.Pool | pg.PoolConfig | string, options?: PrismaPgOptions | undefined);
|
|
43
43
|
connect(): Promise<PrismaPgAdapter>;
|
|
44
44
|
connectToShadowDb(): Promise<PrismaPgAdapter>;
|
|
45
45
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -39,7 +39,7 @@ export declare class PrismaPg implements SqlMigrationAwareDriverAdapterFactory {
|
|
|
39
39
|
readonly adapterName: string;
|
|
40
40
|
private readonly config;
|
|
41
41
|
private externalPool;
|
|
42
|
-
constructor(poolOrConfig: pg.Pool | pg.PoolConfig, options?: PrismaPgOptions | undefined);
|
|
42
|
+
constructor(poolOrConfig: pg.Pool | pg.PoolConfig | string, options?: PrismaPgOptions | undefined);
|
|
43
43
|
connect(): Promise<PrismaPgAdapter>;
|
|
44
44
|
connectToShadowDb(): Promise<PrismaPgAdapter>;
|
|
45
45
|
}
|
package/dist/index.js
CHANGED
|
@@ -781,6 +781,9 @@ var PrismaPgAdapterFactory = class {
|
|
|
781
781
|
if (poolOrConfig instanceof import_pg2.default.Pool) {
|
|
782
782
|
this.externalPool = poolOrConfig;
|
|
783
783
|
this.config = poolOrConfig.options;
|
|
784
|
+
} else if (typeof poolOrConfig === "string") {
|
|
785
|
+
this.externalPool = null;
|
|
786
|
+
this.config = { connectionString: poolOrConfig };
|
|
784
787
|
} else {
|
|
785
788
|
this.externalPool = null;
|
|
786
789
|
this.config = poolOrConfig;
|
package/dist/index.mjs
CHANGED
|
@@ -745,6 +745,9 @@ var PrismaPgAdapterFactory = class {
|
|
|
745
745
|
if (poolOrConfig instanceof pg2.Pool) {
|
|
746
746
|
this.externalPool = poolOrConfig;
|
|
747
747
|
this.config = poolOrConfig.options;
|
|
748
|
+
} else if (typeof poolOrConfig === "string") {
|
|
749
|
+
this.externalPool = null;
|
|
750
|
+
this.config = { connectionString: poolOrConfig };
|
|
748
751
|
} else {
|
|
749
752
|
this.externalPool = null;
|
|
750
753
|
this.config = poolOrConfig;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prisma/adapter-pg",
|
|
3
|
-
"version": "7.6.0-dev.
|
|
3
|
+
"version": "7.6.0-dev.3",
|
|
4
4
|
"description": "Prisma's driver adapter for \"pg\"",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -34,10 +34,10 @@
|
|
|
34
34
|
"pg": "^8.16.3",
|
|
35
35
|
"postgres-array": "3.0.4",
|
|
36
36
|
"@types/pg": "8.11.11",
|
|
37
|
-
"@prisma/driver-adapter-utils": "7.6.0-dev.
|
|
37
|
+
"@prisma/driver-adapter-utils": "7.6.0-dev.3"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
|
-
"@prisma/debug": "7.6.0-dev.
|
|
40
|
+
"@prisma/debug": "7.6.0-dev.3"
|
|
41
41
|
},
|
|
42
42
|
"scripts": {
|
|
43
43
|
"dev": "DEV=true tsx helpers/build.ts",
|