mongodb-schema
Advanced tools
Comparing version
@@ -285,3 +285,5 @@ var es = require('event-stream'); | ||
addToField = function(path, value, schema) { | ||
var field = schema[path] = _.get(schema, path, { | ||
var defaults = {}; | ||
defaults[path] = { | ||
name: _.last(path.split('.')), | ||
@@ -291,3 +293,6 @@ path: path, | ||
types: {} | ||
}); | ||
}; | ||
_.defaultsDeep(schema, defaults); | ||
var field = schema[path]; | ||
field.count++; | ||
@@ -294,0 +299,0 @@ // debug('added to field', field); |
{ | ||
"name": "mongodb-schema", | ||
"description": "Infer the probabilistic schema for a MongoDB collection.", | ||
"version": "8.0.0", | ||
"version": "8.0.1", | ||
"author": "Thomas Rueckstiess <thomas@rueckstiess.net>", | ||
@@ -6,0 +6,0 @@ "license": "Apache-2.0", |
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
44427
0.14%437
0.69%1
Infinity%