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

minimagic

Package Overview
Dependencies
Maintainers
6
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

minimagic - npm Package Compare versions

Comparing version 0.3.2 to 0.3.3

LICENSE

16

MinimatchTree.js
var minimatch = require('minimatch');
var oid = require('oid');

@@ -10,5 +9,16 @@ var MinimatchTree = function() {

var getHash = function (data) {
let symbols = Object.getOwnPropertySymbols(data);
if (symbols.length === 0) {
let symbol = Symbol();
data[symbol] = '__minimagicSymbol';
return symbol;
} else {
return symbols[0];
}
}
MinimatchTree.prototype.add = function (glob, data) {
var globRoot = this._getGlobRoot(glob);
var hash = oid.hash(data);
var hash = getHash(data);
var isNegation = this._isNegation(glob);

@@ -69,3 +79,3 @@ if (isNegation) {

var globRoot = this._getGlobRoot(glob);
var hash = oid.hash(data);
var hash = getHash(data);

@@ -72,0 +82,0 @@ var matches = globRoot === glob ? this._exactMatches[glob] : this._rootData[globRoot];

4

package.json
{
"name": "minimagic",
"description": "fast minimatching",
"version": "0.3.2",
"version": "0.3.3",
"homepage": "https://github.com/azulus/minimagic",

@@ -12,2 +12,3 @@ "authors": [

"main": "./MinimatchTree.js",
"license": "MIT",
"repository": {

@@ -18,3 +19,2 @@ "type": "git",

"dependencies": {
"oid": "1.2.0",
"minimatch": "0.2"

@@ -21,0 +21,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