Skip to content
This repository was archived by the owner on Oct 15, 2024. It is now read-only.

Commit 871e4f2

Browse files
authored
update lambda_function.py
added Image lib and image format
1 parent fa7f1f2 commit 871e4f2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lambda_function.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
from boto3.dynamodb.conditions import Key
1616
from boto3.session import Session
17-
from PIL import ImageOps
17+
from PIL import Image, ImageOps
1818
from twilio.rest import TwilioRestClient
1919

2020

@@ -80,7 +80,7 @@ def lambda_handler(event, context):
8080
# build meta data
8181
m_data = {'fromNumber': from_number, 'url': resp_url, 'name': name}
8282
output = StringIO.StringIO()
83-
im.save(output)
83+
im.save(output, format="PNG")
8484
im_data = output.getvalue()
8585
output.close()
8686

0 commit comments

Comments
 (0)