log the bounce message from SES

This commit is contained in:
Leo Hemsted
2017-11-16 17:46:58 +00:00
parent ff449735e4
commit 1f317b6717

View File

@@ -56,6 +56,7 @@ def process_ses_response(ses_request):
notification_type = ses_message['notificationType']
if notification_type == 'Bounce':
current_app.logger.info('SES bounce dict: {}'.format(ses_message['bounce']))
if ses_message['bounce']['bounceType'] == 'Permanent':
notification_type = ses_message['bounce']['bounceType'] # permanent or not
else: