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

directory-walker

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

directory-walker - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

.npmignore

12

lib/directory-walker/directory-walker.js

@@ -13,2 +13,3 @@ // third-party dependencies

this.onDirectory = config.onDirectory;
this.pending = 0;

@@ -18,3 +19,3 @@ if (config.excludes) {

for (var i = 0; i < config.excludes.length; i++) {
var exclude = path.normalize(config.excludes[i]);
var exclude = path.resolve(config.excludes[i]);
this.excludes[exclude] = true;

@@ -36,8 +37,7 @@ }

DirectoryWalker.prototype.start = function() {
DirectoryWalker.prototype.walk = function(dir) {
// right before we read directory, we increment pending
// right after directory is read, we decrement pending
// when pending drops back to zero then we are down walking
this.pending = 0;
this.readdir(this.basedir);
this.readdir(dir || this.basedir);
};

@@ -75,3 +75,3 @@

var dir = path.normalize(dir);
var dir = path.resolve(dir);
if (this.excludes && this.excludes[dir]) {

@@ -97,3 +97,3 @@ return;

for ( var i = 0; i < files.length; i++) {
var file = path.normalize(dir + '/' + files[i]);
var file = path.resolve(dir + '/' + files[i]);
if (!this.excludes || !this.excludes[dir]) {

@@ -100,0 +100,0 @@ self.visit(file, dir);

{
"name": "directory-walker",
"description": "Directory walker",
"version": "1.0.0",
"version": "1.1.0",
"homepage": "https://github.com/philidem/node-directory-walker",

@@ -6,0 +6,0 @@ "authors": [

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