@mcma/aws-api-gateway
Advanced tools
Comparing version 0.14.7 to 0.14.8
"use strict"; | ||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); | ||
var desc = Object.getOwnPropertyDescriptor(m, k); | ||
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { | ||
desc = { enumerable: true, get: function() { return m[k]; } }; | ||
} | ||
Object.defineProperty(o, k2, desc); | ||
}) : (function(o, m, k, k2) { | ||
@@ -6,0 +10,0 @@ if (k2 === undefined) k2 = k; |
@@ -16,15 +16,7 @@ "use strict"; | ||
async handleRequest(event, context) { | ||
let httpMethod, path; | ||
if (isAPIGatewayProxyEvent(event)) { | ||
httpMethod = event.httpMethod; | ||
path = event.path; | ||
} | ||
else { | ||
httpMethod = event.requestContext.http.method; | ||
path = event.requestContext.http.path.substring(event.requestContext.stage.length + 1); | ||
} | ||
var _a, _b; | ||
const requestContext = new api_1.McmaApiRequestContext(new api_1.McmaApiRequest({ | ||
id: context.awsRequestId, | ||
path, | ||
httpMethod, | ||
path: "/" + ((_b = (_a = event.pathParameters) === null || _a === void 0 ? void 0 : _a.proxy) !== null && _b !== void 0 ? _b : ""), | ||
httpMethod: isAPIGatewayProxyEvent(event) ? event.httpMethod : event.requestContext.http.method, | ||
headers: event.headers, | ||
@@ -31,0 +23,0 @@ pathVariables: {}, |
"use strict"; | ||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); | ||
var desc = Object.getOwnPropertyDescriptor(m, k); | ||
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { | ||
desc = { enumerable: true, get: function() { return m[k]; } }; | ||
} | ||
Object.defineProperty(o, k2, desc); | ||
}) : (function(o, m, k, k2) { | ||
@@ -6,0 +10,0 @@ if (k2 === undefined) k2 = k; |
{ | ||
"name": "@mcma/aws-api-gateway", | ||
"version": "0.14.7", | ||
"version": "0.14.8", | ||
"description": "Node module with code for using AWS's API Gateway as an entry point to an MCMA API handler.", | ||
@@ -37,12 +37,12 @@ "engines": { | ||
"peerDependencies": { | ||
"@mcma/core": "0.14.7", | ||
"@mcma/api": "0.14.7", | ||
"@mcma/core": "0.14.8", | ||
"@mcma/api": "0.14.8", | ||
"@types/aws-lambda": "^8.10.63" | ||
}, | ||
"devDependencies": { | ||
"@mcma/api": "0.14.7", | ||
"@mcma/client": "0.14.7", | ||
"@mcma/core": "0.14.7", | ||
"@mcma/data": "0.14.7", | ||
"@mcma/worker-invoker": "0.14.7", | ||
"@mcma/api": "0.14.8", | ||
"@mcma/client": "0.14.8", | ||
"@mcma/core": "0.14.8", | ||
"@mcma/data": "0.14.8", | ||
"@mcma/worker-invoker": "0.14.8", | ||
"@types/aws-lambda": "^8.10.63", | ||
@@ -49,0 +49,0 @@ "@types/node": "^14.17.22", |
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
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
5724