summaryrefslogtreecommitdiff
path: root/handler.js
diff options
context:
space:
mode:
authorJoe Robinson <joe@lc8n.com>2018-03-06 12:57:28 +0000
committerJoe Robinson <joe@lc8n.com>2018-03-06 12:57:28 +0000
commita6d4523b9ebbbcbedff22201a619f3ba409722ad (patch)
tree2116c957d166d73c7b24fb611b19ba6b140ab7c9 /handler.js
parent991ed910b580a49f7e44176974ee6c2dcf942d18 (diff)
Update handler.js
Diffstat (limited to 'handler.js')
-rw-r--r--handler.js4
1 files changed, 3 insertions, 1 deletions
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;