Don't add numbering to primary key

This commit is contained in:
Mel O'Hagan 2022-11-24 18:24:38 +00:00
parent 38994eb977
commit b2e8522b7b
1 changed files with 5 additions and 1 deletions

View File

@ -28,7 +28,11 @@
function addNumbering(filters) {
let count = 1
for (let value of filters) {
if (value.field && value.field?.match(QUERY_START_REGEX) == null) {
if (
value.field &&
value.field?.match(QUERY_START_REGEX) == null &&
value.field !== "_id"
) {
value.field = `${count++}:${value.field}`
}
}