From ac523554db2b6844f1bf15ac05f1e739cc5ec20c Mon Sep 17 00:00:00 2001 From: andrewquang512 Date: Sat, 16 Dec 2023 14:27:48 +0700 Subject: [PATCH] workaround --- src/handler.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/handler.js b/src/handler.js index dbe0214..5623642 100644 --- a/src/handler.js +++ b/src/handler.js @@ -62,12 +62,11 @@ export const handler = startServerAndCreateLambdaHandler( handlers.createAPIGatewayProxyEventRequestHandler(), { middleware: [ - async (event) => { - console.log('###? received event=' + JSON.stringify(event)); - }, async (event, lambdaContext, callback) => { + console.log('###? received event' + JSON.stringify(event)); // Handle CORS preflight request if (event.httpMethod === 'OPTIONS') { + console.log('###? received event OPTIONS' + JSON.stringify(event)); const response = { statusCode: 200, headers: {