@wll8/json-server
Advanced tools
@@ -68,3 +68,3 @@ "use strict"; | ||
| const keys = Object.keys(db.value()).map(key => `/${key}`); | ||
| opts._noDataNext && keys.length && router.use(keys, nested(opts)); // Create routes | ||
| opts._noDataNext && keys.length ? router.use(keys, nested(opts)) : router.use(nested(opts)); // Create routes | ||
@@ -99,4 +99,3 @@ db.forEach((value, key) => { | ||
| opts._noDataNext && keys.length && router.use(keys, render); | ||
| !opts._noDataNext && router.use(render); | ||
| opts._noDataNext && keys.length ? router.use(keys, render) : router.use(render); | ||
| router.use((err, req, res, next) => { | ||
@@ -103,0 +102,0 @@ console.error(err.stack); |
+3
-2
| { | ||
| "name": "@wll8/json-server", | ||
| "version": "0.17.1", | ||
| "version": "0.17.2-alpha.1", | ||
| "description": "Get a full fake REST API with zero coding in less than 30 seconds", | ||
@@ -19,3 +19,4 @@ "main": "./lib/server/index.js", | ||
| "toc": "markdown-toc -i README.md", | ||
| "postversion": "git push && git push --tags" | ||
| "postversion": "git push && git push --tags", | ||
| "prepublish": "npm test && npm run build" | ||
| }, | ||
@@ -22,0 +23,0 @@ "dependencies": { |
Network access
Supply chain riskThis module accesses the network.
Found 3 instances 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
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
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
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 3 instances 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
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
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
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
65492
0.09%1095
-0.09%