Comparing version 2.0.4 to 2.1.0
@@ -5,3 +5,3 @@ { | ||
"description": "A document path library for Node", | ||
"version": "2.0.4", | ||
"version": "2.1.0", | ||
"repository": { | ||
@@ -8,0 +8,0 @@ "type": "git", |
@@ -39,4 +39,7 @@ 'use strict'; | ||
// If there is a '.' in the keyPath, recur on the subdoc and ... | ||
if (indexOfDot >= 0) { | ||
if (currentKey === '__proto__' || document === Object && currentKey === 'prototype') { | ||
// Refuse to modify anything on __proto__, return the document | ||
return document; | ||
} else if (indexOfDot >= 0) { | ||
// If there is a '.' in the keyPath, recur on the subdoc and ... | ||
if (!document[currentKey] && Array.isArray(document)) { | ||
@@ -43,0 +46,0 @@ // If this is an array and there are multiple levels of keys to iterate over, recur. |
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
8191
66