Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

pelias-query

Package Overview
Dependencies
Maintainers
1
Versions
76
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pelias-query - npm Package Compare versions

Comparing version 1.2.0 to 1.3.0

14

layout/FilteredBooleanQuery.js

@@ -14,3 +14,3 @@

Layout.prototype.filter = function( view ){
this._filter.push([ view, 'must' ]);
this._filter.push( view );
return this;

@@ -43,11 +43,9 @@ };

if( this._filter.length ){
q.query.filtered.filter = { bool: {} };
this._filter.forEach( function( condition ){
var view = condition[0], operator = condition[1];
if( !q.query.filtered.filter.bool.hasOwnProperty( operator ) ){
q.query.filtered.filter.bool[ operator ] = [];
}
this._filter.forEach( function( view ){
var rendered = view( vs );
if( rendered ){
q.query.filtered.filter.bool[ operator ].push( rendered );
if( !q.query.filtered.hasOwnProperty( 'filter' ) ){
q.query.filtered.filter = { bool: { must: [] } };
}
q.query.filtered.filter.bool.must.push( rendered );
}

@@ -54,0 +52,0 @@ });

{
"name": "pelias-query",
"version": "1.2.0",
"version": "1.3.0",
"description": "",

@@ -5,0 +5,0 @@ "main": "index.js",

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc