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

mquery

Package Overview
Dependencies
Maintainers
2
Versions
74
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mquery - npm Package Compare versions

Comparing version 0.2.4 to 0.2.5

mqTest.js

6

History.md
0.2.4 / 2013-07-30
==================
* updated docs
* changed internal representation of `sort` to use objects instead of arrays
0.2.4 / 2013-07-25

@@ -3,0 +9,0 @@ ==================

5

lib/mquery.js

@@ -1188,4 +1188,5 @@ 'use strict';

}
var arr = opts.sort || (opts.sort = []);
arr.push([field, value]);
// store `sort` in a sane format
var s = opts.sort || (opts.sort = {});
s[field] = value;
}

@@ -1192,0 +1193,0 @@

2

package.json
{
"name": "mquery",
"version": "0.2.4",
"version": "0.2.5",
"description": "Expressive query building for MongoDB",

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

@@ -314,3 +314,3 @@ #mquery

query.where('loc').within().circle(area)
query.center('loc', area);
query.circle('loc', area);

@@ -320,3 +320,3 @@ // for spherical calculations

query.where('loc').within().circle(area)
query.center('loc', area);
query.circle('loc', area);
```

@@ -521,2 +521,21 @@

###near()
Specifies arguments for a `$near` or `$nearSphere` condition.
These operators return documents sorted by distance.
####Example
```js
query.where('loc').near({ center: [10, 10] });
query.where('loc').near({ center: [10, 10], maxDistance: 5 });
query.near('loc', { center: [10, 10], maxDistance: 5 });
// For a $nearSphere condition, pass the `spherical` option.
query.near({ center: [10, 10], maxDistance: 5, spherical: true });
```
[MongoDB Documentation](http://www.mongodb.org/display/DOCS/Geospatial+Indexing)
###or()

@@ -523,0 +542,0 @@

Sorry, the diff of this file is too big to display

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