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

object-scan

Package Overview
Dependencies
Maintainers
1
Versions
200
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

object-scan - npm Package Compare versions

Comparing version 1.1.1 to 1.1.2

10

lib/index.js

@@ -23,5 +23,3 @@ const parser = require("./util/parser");

result.push(...find(haystack[i], [check.slice(1)], pathOut));
}
if (check[0] === "**") {
} else if (check[0] === "**") {
result.push(...find(haystack[i], [check, check.slice(1)], pathOut));

@@ -39,5 +37,3 @@ }

result.push(...find(haystack[key], [check.slice(1)], pathOut));
}
if (check[0] === "**") {
} else if (check[0] === "**") {
result.push(...find(haystack[key], [check, check.slice(1)], pathOut));

@@ -55,2 +51,2 @@ }

};
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9pbmRleC5qcyJdLCJuYW1lcyI6WyJwYXJzZXIiLCJyZXF1aXJlIiwibW9kdWxlIiwiZXhwb3J0cyIsIm5lZWRsZXMiLCJ2YWx1ZUZuIiwidW5kZWZpbmVkIiwic2VhcmNoIiwibWFwIiwiZmluZCIsImhheXN0YWNrIiwiY2hlY2tzIiwicGF0aEluIiwicmVzdWx0Iiwic29tZSIsImNoZWNrIiwibGVuZ3RoIiwicHVzaCIsIk9iamVjdCIsIkFycmF5IiwiaXNBcnJheSIsImkiLCJmaWx0ZXIiLCJmb3JFYWNoIiwicGF0aE91dCIsImluZGV4T2YiLCJzbGljZSIsImtleXMiLCJrZXkiLCJlc2NhcGVkS2V5IiwicmVwbGFjZSJdLCJtYXBwaW5ncyI6IkFBQUEsTUFBTUEsU0FBU0MsUUFBUSxlQUFSLENBQWY7O0FBRUFDLE9BQU9DLE9BQVAsR0FBaUIsQ0FBQ0MsT0FBRCxFQUFVQyxVQUFVQyxTQUFwQixLQUFrQztBQUNqRCxRQUFNQyxTQUFTSCxRQUF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NrKSkge1xuICAgICAgICBmb3IgKGxldCBpID0gMDsgaSA8IGhheXN0YWNrLmxlbmd0aDsgaSArPSAxKSB7XG4gICAgICAgICAgY2hlY2tzXG4gICAgICAgICAgICAuZmlsdGVyKGNoZWNrID0+IGNoZWNrLmxlbmd0aCAhPT0gMClcbiAgICAgICAgICAgIC5mb3JFYWNoKChjaGVjaykgPT4ge1xuICAgICAgICAgICAgICBjb25zdCBwYXRoT3V0ID0gYCR7cGF0aEluID09PSB1bmRlZmluZWQgPyBcIlwiIDogcGF0aElufVske2l9XWA7XG4gICAgICAgICAgICAgIGlmIChcbiAgICAgICAgICAgICAgICBjaGVja1swXSA9PT0gXCJbKl1cIiB8fFxuICAgICAgICAgICAgICAgIGNoZWNrWzBdID09PSBgWyR7aX1dYCB8fFxuICAgICAgICAgICAgICAgIChjaGVja1swXSBpbnN0YW5jZW9mIEFycmF5ICYmIGNoZWNrWzBdLmluZGV4T2YoYFske2l9XWApICE9PSAtMSlcbiAgICAgICAgICAgICAgKSB7XG4gICAgICAgICAgICAgICAgcmVzdWx0LnB1c2goLi4uZmluZChoYXlzdGFja1tpXSwgW2NoZWNrLnNsaWNlKDEpXSwgcGF0aE91dCkpO1xuICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIGlmIChjaGVja1swXSA9PT0gXCIqKlwiKSB7XG4gICAgICAgICAgICAgICAgcmVzdWx0LnB1c2goLi4uZmluZChoYXlzdGFja1tpXSwgW2NoZWNrLCBjaGVjay5zbGljZSgxKV0sIHBhdGhPdXQpKTtcbiAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfSk7XG4gICAgICAgIH1cbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIE9iamVjdC5rZXlzKGhheXN0YWNrKS5mb3JFYWNoKChrZXkpID0+IHtcbiAgICAgICAgICBjaGVja3NcbiAgICAgICAgICAgIC5maWx0ZXIoY2hlY2sgPT4gY2hlY2subGVuZ3RoICE9PSAwKVxuICAgICAgICAgICAgLmZvckVhY2goKGNoZWNrKSA9PiB7XG4gICAgICAgICAgICAgIGNvbnN0IGVzY2FwZWRLZXkgPSBrZXkucmVwbGFjZSgvWywuKltcXF17fV0vZywgXCJcXFxcJCZcIik7XG4gICAgICAgICAgICAgIGNvbnN0IHBhdGhPdXQgPSBwYXRoSW4gPT09IHVuZGVmaW5lZCA/IGtleSA6IGAke3BhdGhJbn0uJHtrZXl9YDtcbiAgICAgICAgICAgICAgaWYgKFxuICAgICAgICAgICAgICAgIGNoZWNrWzBdID09PSBcIipcIiB8fFxuICAgICAgICAgICAgICAgIGNoZWNrWzBdID09PSBlc2NhcGVkS2V5IHx8XG4gICAgICAgICAgICAgICAgKGNoZWNrWzBdIGluc3RhbmNlb2YgQXJyYXkgJiYgY2hlY2tbMF0uaW5kZXhPZihlc2NhcGVkS2V5KSAhPT0gLTEpXG4gICAgICAgICAgICAgICkge1xuICAgICAgICAgICAgICAgIHJlc3VsdC5wdXNoKC4uLmZpbmQoaGF5c3RhY2tba2V5XSwgW2NoZWNrLnNsaWNlKDEpXSwgcGF0aE91dCkpO1xuICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIGlmIChjaGVja1swXSA9PT0gXCIqKlwiKSB7XG4gICAgICAgICAgICAgICAgcmVzdWx0LnB1c2goLi4uZmluZChoYXlzdGFja1trZXldLCBbY2hlY2ssIGNoZWNrLnNsaWNlKDEpXSwgcGF0aE91dCkpO1xuICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9KTtcbiAgICAgICAgfSk7XG4gICAgICB9XG4gICAgfVxuICAgIHJldHVybiByZXN1bHQ7XG4gIH07XG5cbiAgcmV0dXJuIGhheXN0YWNrID0+IGZpbmQoaGF5c3RhY2ssIHNlYXJjaCk7XG59O1xuIl19
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9pbmRleC5qcyJdLCJuYW1lcyI6WyJwYXJzZXIiLCJyZXF1aXJlIiwibW9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AgICAgICAgICAgICAgICByZXN1bHQucHVzaCguLi5maW5kKGhheXN0YWNrW2ldLCBbY2hlY2suc2xpY2UoMSldLCBwYXRoT3V0KSk7XG4gICAgICAgICAgICAgIH0gZWxzZSBpZiAoY2hlY2tbMF0gPT09IFwiKipcIikge1xuICAgICAgICAgICAgICAgIHJlc3VsdC5wdXNoKC4uLmZpbmQoaGF5c3RhY2tbaV0sIFtjaGVjaywgY2hlY2suc2xpY2UoMSldLCBwYXRoT3V0KSk7XG4gICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9XG4gICAgICB9IGVsc2Uge1xuICAgICAgICBPYmplY3Qua2V5cyhoYXlzdGFjaykuZm9yRWFjaCgoa2V5KSA9PiB7XG4gICAgICAgICAgY2hlY2tzXG4gICAgICAgICAgICAuZmlsdGVyKGNoZWNrID0+IGNoZWNrLmxlbmd0aCAhPT0gMClcbiAgICAgICAgICAgIC5mb3JFYWNoKChjaGVjaykgPT4ge1xuICAgICAgICAgICAgICBjb25zdCBlc2NhcGVkS2V5ID0ga2V5LnJlcGxhY2UoL1ssLipbXFxde31dL2csIFwiXFxcXCQmXCIpO1xuICAgICAgICAgICAgICBjb25zdCBwYXRoT3V0ID0gcGF0aEluID09PSB1bmRlZmluZWQgPyBrZXkgOiBgJHtwYXRoSW59LiR7a2V5fWA7XG4gICAgICAgICAgICAgIGlmIChcbiAgICAgICAgICAgICAgICBjaGVja1swXSA9PT0gXCIqXCIgfHxcbiAgICAgICAgICAgICAgICBjaGVja1swXSA9PT0gZXNjYXBlZEtleSB8fFxuICAgICAgICAgICAgICAgIChjaGVja1swXSBpbnN0YW5jZW9mIEFycmF5ICYmIGNoZWNrWzBdLmluZGV4T2YoZXNjYXBlZEtleSkgIT09IC0xKVxuICAgICAgICAgICAgICApIHtcbiAgICAgICAgICAgICAgICByZXN1bHQucHVzaCguLi5maW5kKGhheXN0YWNrW2tleV0sIFtjaGVjay5zbGljZSgxKV0sIHBhdGhPdXQpKTtcbiAgICAgICAgICAgICAgfSBlbHNlIGlmIChjaGVja1swXSA9PT0gXCIqKlwiKSB7XG4gICAgICAgICAgICAgICAgcmVzdWx0LnB1c2goLi4uZmluZChoYXlzdGFja1trZXldLCBbY2hlY2ssIGNoZWNrLnNsaWNlKDEpXSwgcGF0aE91dCkpO1xuICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9KTtcbiAgICAgICAgfSk7XG4gICAgICB9XG4gICAgfVxuICAgIHJldHVybiByZXN1bHQ7XG4gIH07XG5cbiAgcmV0dXJuIGhheXN0YWNrID0+IGZpbmQoaGF5c3RhY2ssIHNlYXJjaCk7XG59O1xuIl19
{
"name": "object-scan",
"version": "1.1.1",
"version": "1.1.2",
"description": "Find Keys using Wildcard matching and optional value function.",

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

@@ -77,6 +77,8 @@ # Object-Scan

// => ["a.e.f"]
objectScan(["**[*]"])(obj);
// => ["a.h[0]", "a.h[1]"]
// value function
objectScan(["**"], e => typeof e === "string")(obj);
// => ["a.b.c", "a.e.f", "a.h[0]", "a.h[1]", "k"]
objectScan(["**[*]"])(obj);
// => ["a.h[0]", "a.h[1]"]
```

@@ -83,0 +85,0 @@

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