postcss-loader
Advanced tools
+26
-22
@@ -411,35 +411,39 @@ "use strict"; | ||
| } | ||
| function warningFactory(obj) { | ||
| function warningFactory(warning) { | ||
| let message = ""; | ||
| if (typeof obj.line !== "undefined") { | ||
| message += `(${obj.line}:${obj.column}) `; | ||
| if (typeof warning.line !== "undefined") { | ||
| message += `(${warning.line}:${warning.column}) `; | ||
| } | ||
| if (typeof obj.plugin !== "undefined") { | ||
| message += `from "${obj.plugin}" plugin: `; | ||
| if (typeof warning.plugin !== "undefined") { | ||
| message += `from "${warning.plugin}" plugin: `; | ||
| } | ||
| message += obj.text; | ||
| if (obj.node) { | ||
| message += `\n\nCode:\n ${obj.node.toString()}\n`; | ||
| message += warning.text; | ||
| if (warning.node) { | ||
| message += `\n\nCode:\n ${warning.node.toString()}\n`; | ||
| } | ||
| const warning = new Error(message); | ||
| warning.stack = null; | ||
| return warning; | ||
| const obj = new Error(message, { | ||
| cause: warning | ||
| }); | ||
| obj.stack = null; | ||
| return obj; | ||
| } | ||
| function syntaxErrorFactory(obj) { | ||
| function syntaxErrorFactory(error) { | ||
| let message = "\nSyntaxError\n\n"; | ||
| if (typeof obj.line !== "undefined") { | ||
| message += `(${obj.line}:${obj.column}) `; | ||
| if (typeof error.line !== "undefined") { | ||
| message += `(${error.line}:${error.column}) `; | ||
| } | ||
| if (typeof obj.plugin !== "undefined") { | ||
| message += `from "${obj.plugin}" plugin: `; | ||
| if (typeof error.plugin !== "undefined") { | ||
| message += `from "${error.plugin}" plugin: `; | ||
| } | ||
| message += obj.file ? `${obj.file} ` : "<css input> "; | ||
| message += `${obj.reason}`; | ||
| const code = obj.showSourceCode(); | ||
| message += error.file ? `${error.file} ` : "<css input> "; | ||
| message += `${error.reason}`; | ||
| const code = error.showSourceCode(); | ||
| if (code) { | ||
| message += `\n\n${code}\n`; | ||
| } | ||
| const error = new Error(message); | ||
| error.stack = null; | ||
| return error; | ||
| const obj = new Error(message, { | ||
| cause: error | ||
| }); | ||
| obj.stack = null; | ||
| return obj; | ||
| } |
+1
-1
| { | ||
| "name": "postcss-loader", | ||
| "version": "7.3.1", | ||
| "version": "7.3.2", | ||
| "description": "PostCSS loader for webpack", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
Uses eval
Supply chain riskPackage uses dynamic code execution (e.g., eval()), which is a dangerous practice. This can prevent the code from running in certain environments and increases the risk that the code may contain exploits or malicious behavior.
Found 1 instance in 1 package
Debug access
Supply chain riskUses debug, reflection and dynamic code execution features.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Uses eval
Supply chain riskPackage uses dynamic code execution (e.g., eval()), which is a dangerous practice. This can prevent the code from running in certain environments and increases the risk that the code may contain exploits or malicious behavior.
Found 1 instance in 1 package
Debug access
Supply chain riskUses debug, reflection and dynamic code execution features.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
51666
0.17%671
0.6%