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

ignorefs

Package Overview
Dependencies
Maintainers
1
Versions
138
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ignorefs - npm Package Compare versions

Comparing version 5.0.0-next.1704139385.328d593b9ad6dcd418ffae388fe720728b22205b to 5.0.0-next.1704140686.0e3a9f161700fdf495e9a533d82c5b6f715d1671

18

edition-deno/index.ts
// builtin
import { basename as getBasename } from 'node:path'
import { basename as getBasename, isAbsolute } from 'node:path'

@@ -156,9 +156,11 @@ // external

) {
if (typeof path === 'string')
path = {
absolutePath: path,
relativePath: path,
basename: getBasename(path),
}
return isIgnoredPath(path, opts)
if (typeof path === 'string') {
const result: Path = {}
if (isAbsolute(path)) result.absolutePath = path
else result.relativePath = path
result.basename = getBasename(path)
return isIgnoredPath(result, opts)
} else {
return isIgnoredPath(path, opts)
}
}
// builtin
import { basename as getBasename } from 'path';
import { basename as getBasename, isAbsolute } from 'path';
// external

@@ -91,9 +91,14 @@ import undesiredBasenamesRegExp from 'ignorepatterns';

export default function isIgnoredPathCompatibility(path, opts) {
if (typeof path === 'string')
path = {
absolutePath: path,
relativePath: path,
basename: getBasename(path),
};
return isIgnoredPath(path, opts);
if (typeof path === 'string') {
const result = {};
if (isAbsolute(path))
result.absolutePath = path;
else
result.relativePath = path;
result.basename = getBasename(path);
return isIgnoredPath(result, opts);
}
else {
return isIgnoredPath(path, opts);
}
}

@@ -98,10 +98,15 @@ "use strict";

function isIgnoredPathCompatibility(path, opts) {
if (typeof path === 'string')
path = {
absolutePath: path,
relativePath: path,
basename: (0, path_1.basename)(path),
};
return isIgnoredPath(path, opts);
if (typeof path === 'string') {
const result = {};
if ((0, path_1.isAbsolute)(path))
result.absolutePath = path;
else
result.relativePath = path;
result.basename = (0, path_1.basename)(path);
return isIgnoredPath(result, opts);
}
else {
return isIgnoredPath(path, opts);
}
}
exports.default = isIgnoredPathCompatibility;

@@ -142,10 +142,15 @@ "use strict";

function isIgnoredPathCompatibility(path, opts) {
if (typeof path === 'string')
path = {
absolutePath: path,
relativePath: path,
basename: (0, path_1.basename)(path),
};
return isIgnoredPath(path, opts);
if (typeof path === 'string') {
var result = {};
if ((0, path_1.isAbsolute)(path))
result.absolutePath = path;
else
result.relativePath = path;
result.basename = (0, path_1.basename)(path);
return isIgnoredPath(result, opts);
}
else {
return isIgnoredPath(path, opts);
}
}
exports.default = isIgnoredPathCompatibility;
{
"title": "IgnoreFS",
"name": "ignorefs",
"version": "5.0.0-next.1704139385.328d593b9ad6dcd418ffae388fe720728b22205b",
"version": "5.0.0-next.1704140686.0e3a9f161700fdf495e9a533d82c5b6f715d1671",
"license": "Artistic-2.0",

@@ -6,0 +6,0 @@ "description": "Ignore common and custom patterns of the file system",

// builtin
import { basename as getBasename } from 'path'
import { basename as getBasename, isAbsolute } from 'path'

@@ -156,9 +156,11 @@ // external

) {
if (typeof path === 'string')
path = {
absolutePath: path,
relativePath: path,
basename: getBasename(path),
}
return isIgnoredPath(path, opts)
if (typeof path === 'string') {
const result: Path = {}
if (isAbsolute(path)) result.absolutePath = path
else result.relativePath = path
result.basename = getBasename(path)
return isIgnoredPath(result, opts)
} else {
return isIgnoredPath(path, opts)
}
}

Sorry, the diff of this file is not supported yet

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