Comparing version 2.0.0 to 2.0.1
@@ -48,12 +48,4 @@ 'use strict'; | ||
// Test validation | ||
var validationErrors = this.validate(body, version); | ||
// Return promise | ||
return new Promise(function (resolve, reject) { | ||
/* istanbul ignore if */ | ||
if (validationErrors) { | ||
reject(validationErrors); | ||
} else { | ||
resolve(_this.db.insertAsync(body)); | ||
} | ||
return this.validate(body, version).then(function (data) { | ||
return _this.db.insertAsync(data); | ||
}); | ||
@@ -102,12 +94,4 @@ } | ||
// Test validation | ||
var validationErrors = this.validate(body, version); | ||
// Return promise | ||
return new Promise(function (resolve, reject) { | ||
/* istanbul ignore if */ | ||
if (validationErrors) { | ||
reject(validationErrors); | ||
} else { | ||
resolve(_this3.db.updateAsync(query, { $set: body }, { multi: true })); | ||
} | ||
return this.validate(body, version).then(function (data) { | ||
return _this3.db.updateAsync(query, { $set: data }, { multi: true }); | ||
}); | ||
@@ -114,0 +98,0 @@ } |
{ | ||
"name": "modli-nedb", | ||
"version": "2.0.0", | ||
"version": "2.0.1", | ||
"description": "Modli adapter for NeDB", | ||
@@ -31,3 +31,3 @@ "main": "build/index.js", | ||
"babel": "^5.6.14", | ||
"babel-eslint": "^4.0.5", | ||
"babel-eslint": "~4.1.7", | ||
"babel-istanbul": "^0.3.17", | ||
@@ -34,0 +34,0 @@ "body-parser": "^1.13.3", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
0
18852
107