@m1212e/rumble 0.12.6 → 0.12.8
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/out/index.cjs +2 -2
- package/out/index.cjs.map +1 -1
- package/out/index.d.cts +1 -1
- package/out/index.d.ts +1 -1
- package/out/index.js +2 -2
- package/out/index.js.map +1 -1
- package/package.json +1 -1
package/out/index.d.cts
CHANGED
|
@@ -828,7 +828,7 @@ declare const rumble: <UserContext extends Record<string, any>, DB extends Drizz
|
|
|
828
828
|
* The other helpers use this helper internally so in most cases you do not have to
|
|
829
829
|
* call this helper directly, unless you need the reference to an enum type
|
|
830
830
|
*/
|
|
831
|
-
enum_: <ExplicitEnumVariableName extends keyof (NonNullable<DB["_"]["
|
|
831
|
+
enum_: <ExplicitEnumVariableName extends keyof (NonNullable<DB["_"]["fullSchema"]> extends infer T_2 ? { [K in keyof T_2 as NonNullable<DB["_"]["fullSchema"]>[K] extends drizzle_orm_pg_core0.PgEnum<any> ? K : never]: NonNullable<DB["_"]["fullSchema"]>[K] } : never), EnumColumn extends drizzle_orm_pg_core0.PgEnum<any>, RefName_2 extends string>({
|
|
832
832
|
tsName,
|
|
833
833
|
enumColumn,
|
|
834
834
|
refName
|
package/out/index.d.ts
CHANGED
|
@@ -828,7 +828,7 @@ declare const rumble: <UserContext extends Record<string, any>, DB extends Drizz
|
|
|
828
828
|
* The other helpers use this helper internally so in most cases you do not have to
|
|
829
829
|
* call this helper directly, unless you need the reference to an enum type
|
|
830
830
|
*/
|
|
831
|
-
enum_: <ExplicitEnumVariableName extends keyof (NonNullable<DB["_"]["
|
|
831
|
+
enum_: <ExplicitEnumVariableName extends keyof (NonNullable<DB["_"]["fullSchema"]> extends infer T_2 ? { [K in keyof T_2 as NonNullable<DB["_"]["fullSchema"]>[K] extends drizzle_orm_pg_core0.PgEnum<any> ? K : never]: NonNullable<DB["_"]["fullSchema"]>[K] } : never), EnumColumn extends drizzle_orm_pg_core0.PgEnum<any>, RefName_2 extends string>({
|
|
832
832
|
tsName,
|
|
833
833
|
enumColumn,
|
|
834
834
|
refName
|
package/out/index.js
CHANGED
|
@@ -1182,7 +1182,7 @@ function buildPothosResponseTypeFromGraphQLType({ builder, sqlType, fieldName, n
|
|
|
1182
1182
|
//#region lib/helpers/determineDialectFromSchema.ts
|
|
1183
1183
|
function determineDBDialectFromSchema(schema) {
|
|
1184
1184
|
const found = /* @__PURE__ */ new Set();
|
|
1185
|
-
for (const table of Object.values(schema)) {
|
|
1185
|
+
for (const table of Object.values(schema).map((t) => t.table)) {
|
|
1186
1186
|
if (typeof table !== "object") continue;
|
|
1187
1187
|
if (table instanceof PgTable) found.add("postgres");
|
|
1188
1188
|
else if (table instanceof MySqlTable) found.add("mysql");
|
|
@@ -1194,7 +1194,7 @@ function determineDBDialectFromSchema(schema) {
|
|
|
1194
1194
|
throw new Error(`Multiple dialects found in schema: ${dialects.join(", ")}`);
|
|
1195
1195
|
}
|
|
1196
1196
|
function isPostgresDB(db) {
|
|
1197
|
-
return determineDBDialectFromSchema(db._.
|
|
1197
|
+
return determineDBDialectFromSchema(db._.relations) === "postgres";
|
|
1198
1198
|
}
|
|
1199
1199
|
|
|
1200
1200
|
//#endregion
|