-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Labels
bugConfirmed bugConfirmed bug
Description
Issue
BugFix 0e27e23f (#8222) - fix multiple $regex conditions on same field when using $and
has implement error with $or and $regex
Error => userValue.every is not a function
in
'$regex': function (doc, userValue, parsedField, docFieldValue) {
return fieldExists(docFieldValue) &&
typeof docFieldValue == "string" &&
userValue.every(function (regexValue) {
return regexMatch(docFieldValue, regexValue);
});
},
with Selector
{
"$and": [
{
"$or": [
{
"field1": {
"$regex": "/searchtext/i"
}
},
{
"field2": {
"$regex": "/searchtext/i"
}
},
{
"field3": {
"$regex": "/searchtext/i"
}
},
{
"field4": {
"$regex": "/searchtext/i"
}
}
]
},
{
"fieldA": {
"$exists": true
},
"fieldB": {
"$exists": true
}
}
]
}
Info
- Environment: Browser
- Platform: all
- Adapter: indexeddb
- Server: CouchDB
Reproduce
see up
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugConfirmed bugConfirmed bug