hyperswitch
Advanced tools
Comparing version
@@ -295,3 +295,7 @@ "use strict"; | ||
} | ||
specPaths[scope.prefixPath][methodName] = method; | ||
const methodCopy = Object.assign({}, method); | ||
delete methodCopy['x-setup-handler']; | ||
delete methodCopy['x-request-handler']; | ||
delete methodCopy['x-route-filters']; | ||
specPaths[scope.prefixPath][methodName] = methodCopy; | ||
} | ||
@@ -332,3 +336,3 @@ | ||
reqHandler = scope.operations[method.operationId]; | ||
if (!reqHandler) { | ||
if (!reqHandler && !this._options.disable_handlers) { | ||
throw new Error(`No known handler associated with operationId ${ | ||
@@ -339,4 +343,4 @@ method.operationId}`); | ||
if (reqHandler) { | ||
node.value.methods[methodName] = reqHandler; | ||
if (reqHandler || this._options.disable_handlers) { | ||
node.value.methods[methodName] = reqHandler || {}; | ||
node.value.methods[methodName].spec = method; | ||
@@ -622,2 +626,4 @@ } | ||
delete specRoot['x-route-filters']; | ||
// Reset paths. These are going to be built up during path setup. | ||
@@ -624,0 +630,0 @@ specRoot.paths = {}; |
@@ -60,3 +60,3 @@ "use strict"; | ||
'content-security-policy': "default-src 'none'; " + | ||
"script-src 'self' 'unsafe-inline'; connect-src 'self'; " + | ||
"script-src 'self' 'unsafe-inline'; connect-src *; " + | ||
"style-src 'self' 'unsafe-inline'; img-src 'self'; font-src 'self';" | ||
@@ -63,0 +63,0 @@ }, |
{ | ||
"name": "hyperswitch", | ||
"version": "0.8.6", | ||
"version": "0.8.7", | ||
"description": "REST API creation framework", | ||
@@ -34,3 +34,3 @@ "main": "index.js", | ||
"swagger-ui": "git+https://github.com/wikimedia/swagger-ui#master", | ||
"json-stable-stringify": "git+https://github.com/wikimedia/json-stable-stringify#master", | ||
"json-stable-stringify": "^1.0.1", | ||
"ajv": "^3.7.2", | ||
@@ -37,0 +37,0 @@ "regexp-utils": "^0.3.2" |
Git dependency
Supply chain riskContains a dependency which resolves to a remote git URL. Dependencies fetched from git URLs are not immutable and can be used to inject untrusted code or reduce the likelihood of a reproducible install.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
180343
0.16%4160
0.12%1
-50%4
-20%Updated