@asymmetrik/elastic-querybuilder
Advanced tools
Comparing version 0.9.4 to 0.9.5
@@ -59,3 +59,3 @@ const QueryBuilder = require('../src/index'); | ||
const query = new QueryBuilder() | ||
.raw('min_score', 2) | ||
.raw('min_score', 0) | ||
.raw('query.boost', 1.2) | ||
@@ -68,3 +68,3 @@ .raw('query.minimum_should_match', 1) | ||
size: 15, | ||
min_score: 2, | ||
min_score: 0, | ||
query: { | ||
@@ -71,0 +71,0 @@ match_all: {}, |
@@ -111,2 +111,7 @@ const utils = require('../src/utils'); | ||
test('should be able to add an existent but falsy value', () => { | ||
const query = {}; | ||
utils.applyRawParameter(query, 'min_score', 0); | ||
}); | ||
test('should add properties to the object if the path does not yet exist', () => { | ||
@@ -113,0 +118,0 @@ const south_park = {}; |
{ | ||
"name": "@asymmetrik/elastic-querybuilder", | ||
"version": "0.9.4", | ||
"version": "0.9.5", | ||
"description": "A query builder for Elasticsearch.", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
@@ -28,3 +28,3 @@ const invariant = require('./invariant'); | ||
const applyRawParameter = (object, path, value) => { | ||
invariant((object && path && value), ERRORS.APPLY_RAW_PARAMETER); | ||
invariant((object && path !== undefined && value !== undefined), ERRORS.APPLY_RAW_PARAMETER); | ||
const props = path.split('.'); | ||
@@ -31,0 +31,0 @@ |
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
153642
1962