sonamu 0.4.13 → 0.4.14

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.
Files changed (27) hide show
  1. package/dist/bin/cli.js +51 -51
  2. package/dist/bin/cli.mjs +2 -2
  3. package/dist/{chunk-DMJSNO2L.js → chunk-2WAC2GER.js} +44 -44
  4. package/dist/{chunk-DMJSNO2L.js.map → chunk-2WAC2GER.js.map} +1 -1
  5. package/dist/{chunk-NI37CY4T.mjs → chunk-C3IPIF6O.mjs} +2 -2
  6. package/dist/{chunk-DYFCACHD.js → chunk-EXHKSVTE.js} +7 -7
  7. package/dist/{chunk-QJFHDCBN.mjs → chunk-FCERKIIF.mjs} +2 -2
  8. package/dist/chunk-FCERKIIF.mjs.map +1 -0
  9. package/dist/{chunk-DDJ7T4MA.mjs → chunk-HGIBJYOU.mjs} +2 -2
  10. package/dist/{chunk-NIFOTHBW.mjs → chunk-JKSOJRQA.mjs} +2 -2
  11. package/dist/{chunk-CXAVBVKC.js → chunk-OTKKFP3Y.js} +100 -100
  12. package/dist/{chunk-J6S43O7G.js → chunk-UZ2IY5VE.js} +4 -4
  13. package/dist/database/drivers/knex/base-model.js +8 -8
  14. package/dist/database/drivers/knex/base-model.mjs +3 -3
  15. package/dist/database/drivers/kysely/base-model.js +9 -9
  16. package/dist/database/drivers/kysely/base-model.mjs +3 -3
  17. package/dist/index.js +9 -9
  18. package/dist/index.mjs +3 -3
  19. package/package.json +1 -1
  20. package/src/api/caster.ts +2 -2
  21. package/dist/chunk-QJFHDCBN.mjs.map +0 -1
  22. /package/dist/{chunk-NI37CY4T.mjs.map → chunk-C3IPIF6O.mjs.map} +0 -0
  23. /package/dist/{chunk-DYFCACHD.js.map → chunk-EXHKSVTE.js.map} +0 -0
  24. /package/dist/{chunk-DDJ7T4MA.mjs.map → chunk-HGIBJYOU.mjs.map} +0 -0
  25. /package/dist/{chunk-NIFOTHBW.mjs.map → chunk-JKSOJRQA.mjs.map} +0 -0
  26. /package/dist/{chunk-CXAVBVKC.js.map → chunk-OTKKFP3Y.js.map} +0 -0
  27. /package/dist/{chunk-J6S43O7G.js.map → chunk-UZ2IY5VE.js.map} +0 -0
@@ -16,7 +16,7 @@ import {
16
16
  isStringProp,
17
17
  isTextProp,
18
18
  isVirtualProp
19
- } from "./chunk-QJFHDCBN.mjs";
19
+ } from "./chunk-FCERKIIF.mjs";
20
20
 
21
21
  // src/entity/migrator.ts
22
22
  import _ from "lodash";
@@ -1578,4 +1578,4 @@ export {
1578
1578
  FixtureManagerClass,
1579
1579
  FixtureManager
1580
1580
  };
1581
- //# sourceMappingURL=chunk-NI37CY4T.mjs.map
1581
+ //# sourceMappingURL=chunk-C3IPIF6O.mjs.map
@@ -2,7 +2,7 @@
2
2
 
3
3
 
4
4
 
5
- var _chunkDMJSNO2Ljs = require('./chunk-DMJSNO2L.js');
5
+ var _chunk2WAC2GERjs = require('./chunk-2WAC2GER.js');
6
6
 
7
7
  // src/database/upsert-builder.ts
8
8
  var _uuid = require('uuid');
@@ -20,7 +20,7 @@ async function batchUpdate(db, tableName, ids, rows, chunkSize = 50, trx = null)
20
20
  };
21
21
  if (trx) {
22
22
  for (const chunk of chunks) {
23
- await executeUpdate(chunk, _chunkDMJSNO2Ljs.DB.toClient(trx));
23
+ await executeUpdate(chunk, _chunk2WAC2GERjs.DB.toClient(trx));
24
24
  }
25
25
  } else {
26
26
  await db.trx(async (newTrx) => {
@@ -87,7 +87,7 @@ var UpsertBuilder = class {
87
87
  if (table === void 0) {
88
88
  const tableSpec = (() => {
89
89
  try {
90
- return _chunkDMJSNO2Ljs.EntityManager.getTableSpec(tableName);
90
+ return _chunk2WAC2GERjs.EntityManager.getTableSpec(tableName);
91
91
  } catch (e) {
92
92
  return null;
93
93
  }
@@ -119,7 +119,7 @@ var UpsertBuilder = class {
119
119
  return null;
120
120
  }
121
121
  return uniqueKeyArray.join("---delimiter--");
122
- }).filter(_chunkDMJSNO2Ljs.nonNullable);
122
+ }).filter(_chunk2WAC2GERjs.nonNullable);
123
123
  const uuid = (() => {
124
124
  if (uniqueKeys.length > 0) {
125
125
  for (const uniqueKey of uniqueKeys) {
@@ -180,7 +180,7 @@ var UpsertBuilder = class {
180
180
  )) {
181
181
  throw new Error(`${tableName} \uD574\uACB0\uB418\uC9C0 \uC54A\uC740 \uCC38\uC870\uAC00 \uC788\uC2B5\uB2C8\uB2E4.`);
182
182
  }
183
- const wdb = _chunkDMJSNO2Ljs.DB.toClient(_wdb);
183
+ const wdb = _chunk2WAC2GERjs.DB.toClient(_wdb);
184
184
  const { references, refTables } = Array.from(this.tables).reduce(
185
185
  (r, [, table2]) => {
186
186
  const reference = Array.from(table2.references.values()).find(
@@ -264,7 +264,7 @@ var UpsertBuilder = class {
264
264
  return row;
265
265
  });
266
266
  await batchUpdate(
267
- _chunkDMJSNO2Ljs.DB.toClient(wdb),
267
+ _chunk2WAC2GERjs.DB.toClient(wdb),
268
268
  tableName,
269
269
  whereColumns,
270
270
  rows,
@@ -277,4 +277,4 @@ var UpsertBuilder = class {
277
277
 
278
278
 
279
279
  exports.isRefField = isRefField; exports.UpsertBuilder = UpsertBuilder;
280
- //# sourceMappingURL=chunk-DYFCACHD.js.map
280
+ //# sourceMappingURL=chunk-EXHKSVTE.js.map
@@ -989,7 +989,7 @@ function isZodNumberAnyway(zodType) {
989
989
  } else if (zodType instanceof z3.ZodNullable && zodType._def.innerType instanceof z3.ZodNumber) {
990
990
  return true;
991
991
  } else if (zodType instanceof z3.ZodOptional && zodType._def.innerType instanceof z3.ZodNumber) {
992
- } else if (zodType instanceof z3.ZodOptional && zodType._def.innerType instanceof z3.ZodOptional && zodType._type.def.innerType instanceof z3.ZodNumber) {
992
+ } else if (zodType instanceof z3.ZodOptional && zodType._def?.innerType instanceof z3.ZodOptional && zodType._type?.def?.innerType instanceof z3.ZodNumber) {
993
993
  return true;
994
994
  }
995
995
  return false;
@@ -7620,4 +7620,4 @@ export {
7620
7620
  isTest,
7621
7621
  Sonamu
7622
7622
  };
7623
- //# sourceMappingURL=chunk-QJFHDCBN.mjs.map
7623
+ //# sourceMappingURL=chunk-FCERKIIF.mjs.map