From 540b97a971a9eb63054c04b3613eb422d44ebb0e Mon Sep 17 00:00:00 2001 From: Rechner Fox <659028+rechner@users.noreply.github.com> Date: Mon, 6 Nov 2023 18:18:39 -0800 Subject: [PATCH] Fix error handling (#299) --- registration/views/dealers.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/registration/views/dealers.py b/registration/views/dealers.py index 0b6647fa..8d77cb74 100644 --- a/registration/views/dealers.py +++ b/registration/views/dealers.py @@ -516,8 +516,8 @@ def addNewDealer(request): try: birthdate = tz.localize(datetime.strptime(pda["birthdate"], "%Y-%m-%d")) except ValueError as e: - logger.warning(f"Unable to parse birthdate: {birthdate} - {e}") - return common.abort(400, f"Unable to parse birthdate: {birthdate}") + logger.warning(f"Unable to parse birthdate: {pda['birthdate']} - {e}") + return common.abort(400, f"Unable to parse birthdate: {pda['birthdate']}") event = Event.objects.get(name=evt) attendee = Attendee(