From dd9429bbfaf02c6f4ce14fc19de2685d53bca682 Mon Sep 17 00:00:00 2001 From: Richard Schreiber Date: Tue, 18 Jan 2022 12:27:57 +0100 Subject: [PATCH] Fix: phone being "None" or format not recognized in checkout (#2420) --- src/pretix/presale/checkoutflow.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pretix/presale/checkoutflow.py b/src/pretix/presale/checkoutflow.py index d43644f00d..6e97914d1d 100644 --- a/src/pretix/presale/checkoutflow.py +++ b/src/pretix/presale/checkoutflow.py @@ -709,8 +709,8 @@ class QuestionsStep(QuestionsViewMixin, CartMixin, TemplateFlowStep): if self.cart_customer: initial['email'] = self.cart_customer.email initial['email_repeat'] = self.cart_customer.email - if not initial['phone']: - initial['phone'] = str(self.cart_customer.phone) + if not initial['phone'] and self.cart_customer.phone: + initial['phone'] = self.cart_customer.phone f = ContactForm(data=self.request.POST if self.request.method == "POST" else None, event=self.request.event,