Skip to content

Field level policies always select relations #1978

Closed
@f8k8

Description

@f8k8

Description and expected behavior
When a model has field level policies which reference other models through a relation, the relations are always selected, even if the relation field is not present in the original select.

Environment:

  • ZenStack version: 2.11.5
  • Prisma version: 6.3.1
  • Database type: Postgresql

Additional context
getFieldReadCheckSelector (here) should probably use visitTarget to determine which of the fields with field level policies need to be checked.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions