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 2.3.3 to 3.0.0-rc0

5

History.md

@@ -0,1 +1,6 @@

3.0.0-rc0 / 2017-12-06
======================
* BREAKING CHANGE: remove support for node < 4
* BREAKING CHANGE: remove support for retainKeyOrder, will always be true by default re: Automattic/mongoose#2749
2.3.3 / 2017-11-19

@@ -2,0 +7,0 @@ ==================

50

lib/utils.js

@@ -66,35 +66,17 @@ 'use strict';

var cloneObject = exports.cloneObject = function cloneObject (obj, options) {
var retainKeyOrder = options && options.retainKeyOrder
, minimize = options && options.minimize
, ret = {}
, hasKeys
, keys
, val
, k
, i
var minimize = options && options.minimize;
var ret = {};
var hasKeys;
var keys;
var val;
var k;
var i;
if (retainKeyOrder) {
for (k in obj) {
val = clone(obj[k], options);
for (k in obj) {
val = clone(obj[k], options);
if (!minimize || ('undefined' !== typeof val)) {
hasKeys || (hasKeys = true);
ret[k] = val;
}
if (!minimize || ('undefined' !== typeof val)) {
hasKeys || (hasKeys = true);
ret[k] = val;
}
} else {
// faster
keys = Object.keys(obj);
i = keys.length;
while (i--) {
k = keys[i];
val = clone(obj[k], options);
if (!minimize || ('undefined' !== typeof val)) {
if (!hasKeys) hasKeys = true;
ret[k] = val;
}
}
}

@@ -186,5 +168,3 @@

if ('undefined' === typeof to[key]) {
// make sure to retain key order here because of a bug handling the $each
// operator in mongodb 2.4.4
to[key] = clone(from[key], { retainKeyOrder : 1});
to[key] = clone(from[key]);
} else {

@@ -194,5 +174,3 @@ if (exports.isObject(from[key])) {

} else {
// make sure to retain key order here because of a bug handling the
// $each operator in mongodb 2.4.4
to[key] = clone(from[key], { retainKeyOrder : 1});
to[key] = clone(from[key]);
}

@@ -199,0 +177,0 @@ }

{
"name": "mquery",
"version": "2.3.3",
"version": "3.0.0-rc0",
"description": "Expressive query building for MongoDB",

@@ -5,0 +5,0 @@ "main": "lib/mquery.js",

Sorry, the diff of this file is not supported yet

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