Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/make/optimize-join-and-where.js
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ function extractNestedMatches(matches) {
const value = matches[orIndex];
ors.push(value);
}
const combined = ands.concat(orIndexes).sort((a, b) => b - a);
const combined = andIndexes.concat(orIndexes).sort((a, b) => b - a);
for (const index of combined) {
matches.splice(index, 1);
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@synatic/noql",
"version": "4.1.15",
"version": "4.1.16",
"description": "Convert SQL statements to mongo queries or aggregates",
"main": "index.js",
"files": [
Expand Down
3 changes: 3 additions & 0 deletions test/bug-fix-tests/bug-fix.json
Original file line number Diff line number Diff line change
Expand Up @@ -1070,5 +1070,8 @@
}
]
}
},
"and-or-nor": {
"case-1": {}
}
}
Loading
Loading