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 8.2.0 to 8.3.0

test/view/categories.js

1

defaults.json

@@ -6,2 +6,3 @@ {

"centroid:field": "center_point",
"categories:field": "category",

@@ -8,0 +9,0 @@ "sort:distance:order": "asc",

@@ -22,2 +22,3 @@

multi_match: require('./view/multi_match'),
categories: require('./view/categories'),
boundary_circle: require('./view/boundary_circle'),

@@ -24,0 +25,0 @@ boundary_rect: require('./view/boundary_rect'),

22

lib/Variable.js
/**
A primitive Javascript variable wrapped in an Object so that it can be
handled by reference instead of by value.
A primitive Javascript variable wrapped in an Object so that it can be
handled by reference instead of by value.
This is useful as an inline variable placeholder where the value may or
may not be known when the query is constructed.
This is useful as an inline variable placeholder where the value may or
may not be known when the query is constructed.
note: values must be a valid js primitive type (string,numeric,boolean),
or an Array. No objects allowed.
note: the object prototype contains custom serialization methods
note: values must be a valid js primitive type (string,numeric,boolean),
or an Array. No objects allowed.
note: the object prototype contains custom serialization methods
warning: using an instance of Variable() in a boolean operation will
*always* yield true; regardless of the underlying value; because js.
**/
warning: using an instance of Variable() in a boolean operation will
*always* yield true; regardless of the underlying value; because js.
**/

@@ -37,2 +37,2 @@ var check = require('check-types');

module.exports = Variable;
module.exports = Variable;
{
"name": "pelias-query",
"version": "8.3.0",
"description": "An Elasticsearch query builder for Pelias",
"main": "index.js",
"version": "8.2.0",
"scripts": {

@@ -7,0 +7,0 @@ "lint": "jshint .",

@@ -143,2 +143,4 @@ >This repository is part of the [Pelias](https://github.com/pelias/pelias)

input:categories: "food,education"
boundary:circle:lat: 1

@@ -145,0 +147,0 @@ boundary:circle:lon: 2

@@ -60,4 +60,7 @@

v.set(false);
t.equal(v.$, false, 'bolean');
t.equal(v.$, false, 'boolean');
v.set([1, 2, 3]);
t.isEquivalent(v.$, [1, 2, 3], 'array');
v.set(['a', 'b']);

@@ -107,2 +110,8 @@ t.deepEqual(v.$, ['a', 'b'], 'array');

});
test('toString: array', function(t) {
var v = new Variable();
v.set([1, 2, 3]);
t.equal(''+v.toString(), '1,2,3', 'array');
t.end();
});
};

@@ -123,2 +132,8 @@

});
test('toJSON: array', function(t) {
var v = new Variable();
v.set([1, 2, 3]);
t.equal(JSON.stringify({ test: v }), '{"test":[1,2,3]}', 'array');
t.end();
});
};

@@ -125,0 +140,0 @@

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