From a4ce1451455c49cbd126512dc8cccc0d5cefc9ce Mon Sep 17 00:00:00 2001 From: Wesley B <62723358+wesleyboar@users.noreply.github.com> Date: Thu, 21 Dec 2023 11:54:59 -0600 Subject: [PATCH] fix: tup-675 submit form without email gives 500 (#399) * fix: tup-675 tour request form 500 error on submit * fix: tup-675 incorrect syntax to check for email prop --- apps/tup-cms/src/apps/portal/apps.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/tup-cms/src/apps/portal/apps.py b/apps/tup-cms/src/apps/portal/apps.py index 0f828424a..e0fb31c0d 100644 --- a/apps/tup-cms/src/apps/portal/apps.py +++ b/apps/tup-cms/src/apps/portal/apps.py @@ -70,7 +70,7 @@ def callback(form, cleaned_data, **kwargs): logger.debug(f"received submission from {form.name}") if form.name == 'rt-ticket-form': submit_ticket(cleaned_data) - else: + elif hasattr(cleaned_data, "email"): send_confirmation_email(form.name, cleaned_data)