mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-03 09:51:11 -05:00
remove some legacy code/tests relating to old invite/verification code
This commit is contained in:
@@ -77,15 +77,6 @@ def process_ses_response():
|
||||
notification_statistics_status = aws_response_dict['notification_statistics_status']
|
||||
|
||||
try:
|
||||
source = ses_message['mail']['source']
|
||||
if is_not_a_notification(source):
|
||||
current_app.logger.info(
|
||||
"SES callback for notify success:. source {} status {}".format(source, notification_status)
|
||||
)
|
||||
return jsonify(
|
||||
result="success", message="SES callback succeeded"
|
||||
), 200
|
||||
|
||||
reference = ses_message['mail']['messageId']
|
||||
if not notifications_dao.update_notification_status_by_reference(
|
||||
reference,
|
||||
@@ -118,18 +109,6 @@ def process_ses_response():
|
||||
raise InvalidRequest(error, status_code=400)
|
||||
|
||||
|
||||
def is_not_a_notification(source):
|
||||
invite_email = "{}@{}".format(
|
||||
current_app.config['INVITATION_EMAIL_FROM'],
|
||||
current_app.config['NOTIFY_EMAIL_DOMAIN']
|
||||
)
|
||||
if current_app.config['VERIFY_CODE_FROM_EMAIL_ADDRESS'] == source:
|
||||
return True
|
||||
if invite_email == source:
|
||||
return True
|
||||
return False
|
||||
|
||||
|
||||
@notifications.route('/notifications/sms/mmg', methods=['POST'])
|
||||
def process_mmg_response():
|
||||
client_name = 'MMG'
|
||||
|
||||
Reference in New Issue
Block a user