broccoli-funnel
Advanced tools
Comparing version 3.0.1 to 3.0.2
20
index.js
@@ -11,2 +11,3 @@ 'use strict'; | ||
const heimdall = require('heimdalljs'); | ||
const fs = require('fs'); | ||
@@ -46,2 +47,15 @@ function ApplyPatchesSchema() { | ||
} | ||
function existsSync(path) { | ||
let error = {}; | ||
try { | ||
fs.accessSync(path); | ||
fs.statSync(path); | ||
} catch (err) { | ||
error = err; | ||
} | ||
if (error.errno && error.errno !== 0) { | ||
return false; | ||
} | ||
return true; | ||
} | ||
@@ -213,2 +227,8 @@ class Funnel extends Plugin { | ||
let outputPathExists = this.output.existsSync('./'); | ||
// We need to keep this till node 10,12 get fix for windows broken symlink issue. | ||
// https://github.com/nodejs/node/issues/30538 | ||
let isWin = process.platform === 'win32'; | ||
if (isWin) { | ||
outputPathExists = existsSync(this.outputPath); | ||
} | ||
@@ -215,0 +235,0 @@ // Doesn't count as a rebuild if there's not an existing outputPath. |
{ | ||
"name": "broccoli-funnel", | ||
"version": "3.0.1", | ||
"version": "3.0.2", | ||
"description": "Broccoli plugin that allows you to filter files selected from an input node down based on regular expressions.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
28279
424
2