Skip to content

in doesn't filter polymorphic relationship when using uuid and empty array #16195

Open

Description

@Xmaster6y

Describe the Bug

Queries with in:[] on polymorphic relationship doesn't work when using uuid.

access: {
    read: () => ({
      'permissions.entity.value': { in: [] },
    }),
  },

Would not filter anything.

Only saw this #10788 as related.

Link to the code that reproduces this issue

https://github.com/Xmaster6y/bug-in

Reproduction Steps

  1. Create a group or user
  2. Create a page
  3. Go to the page listing an observe the query not being satisfied

Which area(s) are affected?

area: core

Environment Info

Binaries:
  Node: 24.8.0
  npm: 11.11.0
  Yarn: 1.22.22
  pnpm: 10.17.0
Relevant Packages:
  payload: 3.81.0
  next: 16.2.1
  @payloadcms/db-sqlite: 3.81.0
  @payloadcms/drizzle: 3.81.0
  @payloadcms/graphql: 3.81.0
  @payloadcms/next/utilities: 3.81.0
  @payloadcms/richtext-lexical: 3.81.0
  @payloadcms/translations: 3.81.0
  @payloadcms/ui/shared: 3.81.0
  react: 19.2.4
  react-dom: 19.2.4
Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 24.6.0: Mon Jul 14 11:29:54 PDT 2025; root:xnu-11417.140.69~1/RELEASE_ARM64_T8122
  Available memory (MB): 16384
  Available CPU cores: 8

Activity

  1. added
    status: needs-triage
    validate-reproduction
    on Apr 7, 2026
  2. added
    area: core
    and removed
    validate-reproduction
    on Apr 7, 2026
  3. Xmaster6y commented on May 3, 2026

    @Xmaster6y
    Author

    Any news?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: corestalestatus: needs-triage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions