@zenstackhq/orm 3.9.3 → 3.9.4-beta.1
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.cjs +2 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +2 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +8 -8
package/dist/index.cjs
CHANGED
|
@@ -6436,7 +6436,8 @@ var QueryNameMapper = class extends kysely.OperationNodeTransformer {
|
|
|
6436
6436
|
}
|
|
6437
6437
|
processEnumSelection(selection, fieldName) {
|
|
6438
6438
|
const { alias, node } = stripAlias(selection);
|
|
6439
|
-
const
|
|
6439
|
+
const qualifier = kysely.ReferenceNode.is(node) && node.table && kysely.TableNode.is(node.table) ? node.table.table.identifier.name : void 0;
|
|
6440
|
+
const fieldScope = this.resolveFieldFromScopes(fieldName, qualifier);
|
|
6440
6441
|
if (!fieldScope || !fieldScope.model) return selection;
|
|
6441
6442
|
const aliasName = alias && kysely.IdentifierNode.is(alias) ? alias.name : fieldName;
|
|
6442
6443
|
const fieldDef = getField(this.schema, fieldScope.model, fieldName);
|