Socket
Socket
Sign inDemoInstall

find-file

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

find-file - npm Package Compare versions

Comparing version 0.1.3 to 0.1.4

11

index.js

@@ -25,3 +25,2 @@ 'use strict';

opts.path = Array.isArray(opts.path) ? opts.path : [opts.path];
opts.exclude = Array.isArray(opts.exclude) ? opts.exclude : [opts.exclude];
opts.global = opts.global !== false;

@@ -33,4 +32,12 @@

if (opts.exclude) {
opts.exclude = Array.isArray(opts.exclude) ? opts.exclude : [opts.exclude];
}
file = opts.path.map(function (dir) {
if (dir && dir.indexOf(opts.exclude) === -1) {
if (dir && opts.exclude) {
if (dir.indexOf(opts.exclude) === -1) {
return path.join(dir, name);
}
} else if (dir) {
return path.join(dir, name);

@@ -37,0 +44,0 @@ }

2

package.json
{
"name": "find-file",
"version": "0.1.3",
"version": "0.1.4",
"description": "Search for a file in an array of paths",

@@ -5,0 +5,0 @@ "keywords": [

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