From 97eafc44f9fbf92b8d4d0d21581291f1b77c8132 Mon Sep 17 00:00:00 2001 From: Dickson Armijos Date: Wed, 14 Oct 2020 14:45:22 -0500 Subject: [PATCH 1/2] feat: Add logs --- src/handlers/get-data/app.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/handlers/get-data/app.js b/src/handlers/get-data/app.js index e25a74d..9e276b8 100644 --- a/src/handlers/get-data/app.js +++ b/src/handlers/get-data/app.js @@ -2,12 +2,13 @@ let response; exports.lambdaHandler = async (event, context) => { + const body = JSON.parse(event.body) + console.info(JSON.parse(context)) try { response = { 'statusCode': 200, 'body': JSON.stringify({ message: 'get data', - // location: ret.data.trim() }) } } catch (err) { From 249f9b00305969619b3d59d0c60d765ba5bd7453 Mon Sep 17 00:00:00 2001 From: Dickson Armijos Date: Wed, 14 Oct 2020 14:48:52 -0500 Subject: [PATCH 2/2] fix: remove body parse --- src/handlers/get-data/app.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/handlers/get-data/app.js b/src/handlers/get-data/app.js index 9e276b8..7ad02a8 100644 --- a/src/handlers/get-data/app.js +++ b/src/handlers/get-data/app.js @@ -2,7 +2,6 @@ let response; exports.lambdaHandler = async (event, context) => { - const body = JSON.parse(event.body) console.info(JSON.parse(context)) try { response = {