Skip to content

Commit

Permalink
Fix notEqual operation for enum filter (#2930)
Browse files Browse the repository at this point in the history
Co-authored-by: Julia Wegmayr <[email protected]>
Co-authored-by: Johannes Obermair <[email protected]>
  • Loading branch information
3 people authored Dec 18, 2024
1 parent 20ec460 commit fb2297b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/blue-trains-roll.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@comet/cms-api": patch
---

Fix `notEqual` operation for enum filter
2 changes: 1 addition & 1 deletion packages/api/cms-api/src/common/filter/mikro-orm.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ export function filterToMikroOrmQuery(
if (filterProperty.equal !== undefined) {
ret.$eq = filterProperty.equal;
}
if (filterProperty.equal !== undefined) {
if (filterProperty.notEqual !== undefined) {
ret.$ne = filterProperty.notEqual;
}
if (filterProperty.isAnyOf !== undefined) {
Expand Down

0 comments on commit fb2297b

Please sign in to comment.