Filter "in" with empty parameter returns all entries
Author: DerIch27Created Sep 28, 2026Updated Sep 28, 2026
Labelsissue: bugseverity: mediumstatus: pending reproductionversion: 5
Node Version
22.22.0
Package Manager
npm
Package Manager Version
10.9.4
Strapi Version
5.40.0
Operating System
Linux (Debian/Ubuntu)
Database
PostgreSQL
Javascript or Typescript
Javascript
Bug Description
See #16324.
When submitting a GraphQL query with the filter "in" and an empty array, Strapi will return all records from the table instead of no records.
This issue persists in Strapi 5.
Steps to Reproduce
query {
someCollection(filters: { "id": { "in": [] } }) {
id
}
}Expected Behavior
No entries are returned when empty array is used with "in" filter.
Confirmation Checklist
- I have checked the existing issues for duplicates.
- I agree to follow this project's Code of Conduct.
Source: strapi/strapi