From bdd2031a22f89e7f0b9fc3e2f33db8936c269fd5 Mon Sep 17 00:00:00 2001 From: "Y.H LIEN" <85728908+LIEN-YUHSIANG@users.noreply.github.com> Date: Thu, 12 Oct 2023 22:58:09 +0900 Subject: [PATCH] chore: fix sync imgs (#345) --- src/lambda/sync-image/index.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/lambda/sync-image/index.py b/src/lambda/sync-image/index.py index 8dc8889eb..b2502ede7 100644 --- a/src/lambda/sync-image/index.py +++ b/src/lambda/sync-image/index.py @@ -10,7 +10,7 @@ def post_imgskey(key): dt_now = datetime.now().strftime('%Y-%m-%dT%H:%M:%S.%f')[:-3] + 'Z' # Creaet board_id, ads_id from the event payload we got - board_id, ads_id, _ = key.split('/') + board_id, ads_id = key.split('/') # Create new item in the dynamoDB item = { @@ -29,6 +29,7 @@ def post_imgskey(key): def handler(event, context): + print(event) # Get event payload and get imgs information key = event['Records'][0]['s3']['object']['key']