1
0
Fork 0
mirror of synced 2024-06-30 12:00:31 +12:00
This commit is contained in:
mike12345567 2021-07-19 14:32:14 +01:00
parent 85f7b056d2
commit 2bee1b6b56

View file

@ -150,14 +150,18 @@ class QueryBuilder {
build(this.query.equal, (key, value) => {
const escapedValue = luceneEscape(value.toLowerCase())
// have to do the or to manage straight values, or strings
return value ? `(${key}:${escapedValue} OR ${key}:"${escapedValue}")` : null
return value
? `(${key}:${escapedValue} OR ${key}:"${escapedValue}")`
: null
})
}
if (this.query.notEqual) {
build(this.query.notEqual, (key, value) => {
const escapedValue = luceneEscape(value.toLowerCase())
// have to do the or to manage straight values, or strings
return value ? `(!${key}:${escapedValue} OR !${key}:"${escapedValue}")` : null
return value
? `(!${key}:${escapedValue} OR !${key}:"${escapedValue}")`
: null
})
}
if (this.query.empty) {