@mikro-orm/knex 6.0.0-dev.257 → 6.0.0-dev.258

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.
@@ -859,9 +859,9 @@ class AbstractSqlDriver extends core_1.DatabaseDriver {
859
859
  mapPropToFieldNames(qb, prop, tableAlias) {
860
860
  const knex = this.connection.getKnex();
861
861
  const aliased = knex.ref(tableAlias ? `${tableAlias}__${prop.fieldNames[0]}` : prop.fieldNames[0]).toString();
862
- if (tableAlias && prop.customTypes?.some(type => type.convertToJSValueSQL)) {
862
+ if (tableAlias && prop.customTypes?.some(type => type?.convertToJSValueSQL)) {
863
863
  return prop.fieldNames.map((col, idx) => {
864
- if (!prop.customTypes[idx].convertToJSValueSQL) {
864
+ if (!prop.customTypes[idx]?.convertToJSValueSQL) {
865
865
  return col;
866
866
  }
867
867
  const prefixed = knex.ref(col).withSchema(tableAlias).toString();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mikro-orm/knex",
3
- "version": "6.0.0-dev.257",
3
+ "version": "6.0.0-dev.258",
4
4
  "description": "TypeScript ORM for Node.js based on Data Mapper, Unit of Work and Identity Map patterns. Supports MongoDB, MySQL, PostgreSQL and SQLite databases as well as usage with vanilla JavaScript.",
5
5
  "main": "index.js",
6
6
  "module": "index.mjs",
@@ -66,6 +66,6 @@
66
66
  "@mikro-orm/core": "^5.9.2"
67
67
  },
68
68
  "peerDependencies": {
69
- "@mikro-orm/core": "6.0.0-dev.257"
69
+ "@mikro-orm/core": "6.0.0-dev.258"
70
70
  }
71
71
  }