Socket
Socket
Sign inDemoInstall

pelias-query

Package Overview
Dependencies
1
Maintainers
5
Versions
76
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 6.3.0 to 7.0.0

.jshintignore

7

layout/FilteredBooleanQuery.js

@@ -25,3 +25,3 @@

var q = Layout.base( vs );
// handle scoring views under 'query' section (both 'must' & 'should')

@@ -57,5 +57,2 @@ if( this._score.length ){

this._sort.forEach( function( view ){
if( !Array.isArray( q.sort ) ){
q.sort = [];
}
var rendered = view( vs );

@@ -86,2 +83,2 @@ if( rendered ){

module.exports = Layout;
module.exports = Layout;
{
"name": "pelias-query",
"version": "6.3.0",
"version": "7.0.0",
"description": "An Elasticsearch query builder for Pelias",
"main": "index.js",
"scripts": {
"lint": "jshint .",
"units": "node test/run.js | tap-spec",
"test": "npm run units"
"test": "npm run units",
"validate": "npm ls"
},

@@ -15,3 +17,3 @@ "repository": {

"author": "",
"license": "ISC",
"license": "MIT",
"bugs": {

@@ -22,8 +24,15 @@ "url": "https://github.com/pelias/query/issues"

"dependencies": {
"check-types": "^6.0.0"
"check-types": "^7.0.0"
},
"devDependencies": {
"jshint": "^2.5.6",
"precommit-hook": "^3.0.0",
"tap-spec": "^4.1.0",
"tape": "^4.2.0"
}
},
"pre-commit": [
"lint",
"validate",
"test"
]
}

@@ -82,3 +82,3 @@

var placeholder = vs.var('a');
t.equal(vs._vars['a'].get(), '');
t.equal(vs._vars.a.get(), '');
t.equal(placeholder.get(), '');

@@ -93,3 +93,3 @@

vs.var('a','b');
t.equal(vs._vars['a'].get(), 'b');
t.equal(vs._vars.a.get(), 'b');

@@ -102,3 +102,3 @@ t.end();

vs.var('a','b');
t.equal(vs._vars['a'].get(), 'b');
t.equal(vs._vars.a.get(), 'b');

@@ -150,6 +150,6 @@ t.end();

t.false(vs.isset('b'));
vs.var('c',false);
t.true(vs.isset('c'));
vs.var('d','test');

@@ -243,3 +243,3 @@ t.true(vs.isset('d'));

var vs = new VariableStore();
t.deepEqual(vs.export(), {});

@@ -249,3 +249,3 @@

t.deepEqual(vs.export(), {a: 1.1});
t.end();

@@ -252,0 +252,0 @@ });

@@ -6,4 +6,21 @@

var tests = [
require('./layout/FilteredBooleanQuery.js'),
require('./lib/Variable.js'),
require('./lib/VariableStore.js')
require('./lib/VariableStore.js'),
require('./view/address.js'),
require('./view/admin.js'),
require('./view/admin_multi_match.js'),
require('./view/boundary_circle.js'),
require('./view/boundary_country.js'),
require('./view/boundary_rect.js'),
require('./view/focus.js'),
require('./view/localregions.js'),
require('./view/multi_match.js'),
require('./view/ngrams.js'),
require('./view/phrase.js'),
require('./view/popularity.js'),
require('./view/population.js'),
require('./view/sort_distance.js'),
require('./view/sort_numeric_script.js'),
require('./view/sources.js')
];

@@ -10,0 +27,0 @@

@@ -20,4 +20,4 @@

// base view
var view = { "match": {} };
var view = { 'match': {} };
// match query

@@ -32,2 +32,2 @@ view.match[ vs.var('address:'+property+':field') ] = {

};
};
};

@@ -10,3 +10,3 @@ /**

*/
module.exports = function( admin_properties ){
module.exports = function( admin_properties, analyzer ){
return function( vs ){

@@ -46,3 +46,3 @@

// send the parameters to the standard multi_match view
var view = multi_match(vs, fields_with_boosts, 'peliasAdmin', queryVar);
var view = multi_match(vs, fields_with_boosts, analyzer, queryVar);

@@ -49,0 +49,0 @@ return view;

@@ -20,4 +20,4 @@

// base view
var view = { "match": {} };
var view = { 'match': {} };
// match query

@@ -32,2 +32,2 @@ view.match[ vs.var('admin:'+property+':field') ] = {

};
};
};

@@ -12,3 +12,3 @@

// base view
var view = { "match": {} };
var view = { 'match': {} };

@@ -22,2 +22,2 @@ // match query

return view;
};
};

@@ -13,4 +13,4 @@

// base view
var view = { "match": {} };
var view = { 'match': {} };
// match query

@@ -24,2 +24,2 @@ view.match[ vs.var('ngram:field') ] = {

return view;
};
};

@@ -8,3 +8,3 @@

!vs.isset('phrase:field') ||
!vs.isset('phrase:boost'),
!vs.isset('phrase:boost') ||
!vs.isset('phrase:slop') ){

@@ -15,4 +15,4 @@ return null;

// base view
var view = { "match": {} };
var view = { 'match': {} };
// match query

@@ -28,2 +28,2 @@ view.match[ vs.var('phrase:field') ] = {

return view;
};
};

@@ -12,3 +12,3 @@

if( !vs.isset('popularity:field') ||
!vs.isset('popularity:modifier'),
!vs.isset('popularity:modifier') ||
!vs.isset('popularity:max_boost') ){

@@ -15,0 +15,0 @@ return null;

@@ -12,3 +12,3 @@

if( !vs.isset('population:field') ||
!vs.isset('population:modifier'),
!vs.isset('population:modifier') ||
!vs.isset('population:max_boost') ){

@@ -15,0 +15,0 @@ return null;

@@ -17,3 +17,3 @@

var view = {
"_script": {
'_script': {
'file': script_name,

@@ -27,2 +27,2 @@ 'type': 'number',

};
};
};

@@ -11,2 +11,2 @@ module.exports = function( vs ){

};
}
};
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc