orchid-orm 1.9.16 → 1.9.18

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.mjs CHANGED
@@ -1265,6 +1265,9 @@ const makeRelationQuery = (table, relationName, data, q) => {
1265
1265
  get() {
1266
1266
  var _a;
1267
1267
  const toTable = q.clone();
1268
+ if (this.query.joinRelationAs) {
1269
+ toTable._as(this.query.joinRelationAs);
1270
+ }
1268
1271
  const query = this.isSubQuery ? toTable : toTable._whereExists(
1269
1272
  this.baseQuery,
1270
1273
  (q2) => data.reverseJoin(this, toTable)