From a6d4523b9ebbbcbedff22201a619f3ba409722ad Mon Sep 17 00:00:00 2001 From: Joe Robinson Date: Tue, 6 Mar 2018 12:57:28 +0000 Subject: Update handler.js --- handler.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/handler.js b/handler.js index cf4fbad..ad6eb1d 100644 --- a/handler.js +++ b/handler.js @@ -7,7 +7,9 @@ const s3 = new AWS.S3(); module.exports.save = (event, context, callback) => { console.log(event.Records[0].kinesis); - fetch(event.image_url) + var url = new Buffer(event.Records[0].kinesis.data, 'base64').toString('utf8'); + console.log(url); + fetch(url) .then((response) => { if (response.ok) { return response; -- cgit v1.2.3