From 6e78541008c07434aa208c8ae1de62463ede31b8 Mon Sep 17 00:00:00 2001 From: Pea Tyczynska Date: Thu, 26 Mar 2020 17:44:16 +0000 Subject: [PATCH] Fix bug where adding same reply-to-email twice for the same service caused a 5xx This was due to changed quotataion marks in error message. --- app/main/views/service_settings.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/main/views/service_settings.py b/app/main/views/service_settings.py index 614f861d9..34081cdbb 100644 --- a/app/main/views/service_settings.py +++ b/app/main/views/service_settings.py @@ -391,7 +391,7 @@ def service_add_email_reply_to(service_id): service_id, form.email_address.data )["data"]["id"] except HTTPError as e: - error_msg = "Your service already uses '{}' as an email reply-to address.".format(form.email_address.data) + error_msg = "Your service already uses ‘{}’ as an email reply-to address.".format(form.email_address.data) if e.status_code == 400 and error_msg == e.message: flash(error_msg, 'error') return redirect(url_for('.service_email_reply_to', service_id=service_id)) @@ -519,7 +519,7 @@ def service_edit_email_reply_to(service_id, reply_to_email_id): service_id, form.email_address.data )["data"]["id"] except HTTPError as e: - error_msg = "Your service already uses ‘{}’ as a reply-to email address.".format(form.email_address.data) + error_msg = "Your service already uses ‘{}’ as an email reply-to address.".format(form.email_address.data) if e.status_code == 400 and error_msg == e.message: flash(error_msg, 'error') return redirect(url_for('.service_email_reply_to', service_id=service_id))