@synatic/noql
Advanced tools
Comparing version 4.1.18 to 4.1.19
@@ -23,4 +23,4 @@ const makeFilterConditionModule = require('./makeFilterCondition'); | ||
branches: whens.map((w) => { | ||
return { | ||
case: makeFilterConditionModule.makeFilterCondition( | ||
const caseCondition = | ||
makeFilterConditionModule.makeFilterCondition( | ||
w.cond, | ||
@@ -35,4 +35,5 @@ context, | ||
true | ||
), | ||
then: makeFilterConditionModule.makeFilterCondition( | ||
); | ||
const thenCondition = | ||
makeFilterConditionModule.makeFilterCondition( | ||
w.result, | ||
@@ -45,3 +46,6 @@ context, | ||
true | ||
), | ||
); | ||
return { | ||
case: caseCondition, | ||
then: thenCondition, | ||
}; | ||
@@ -48,0 +52,0 @@ }), |
@@ -5,2 +5,3 @@ const makeProjectionExpressionPartModule = require('./makeProjectionExpressionPart'); | ||
const $check = require('check-types'); | ||
const makeCaseConditionModule = require('./makeCaseCondition'); | ||
@@ -123,2 +124,5 @@ exports.makeFilterCondition = makeFilterCondition; | ||
} | ||
if (queryPart.type === 'case') { | ||
return makeCaseConditionModule.makeCaseCondition(queryPart, context); | ||
} | ||
@@ -125,0 +129,0 @@ throw new Error( |
{ | ||
"name": "@synatic/noql", | ||
"version": "4.1.18", | ||
"version": "4.1.19", | ||
"description": "Convert SQL statements to mongo queries or aggregates", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
364005
9440