From 324eeb8d40bcf82d242ed9765b5edc9ba8141093 Mon Sep 17 00:00:00 2001 From: luelista Date: Tue, 9 Dec 2025 08:09:34 +0100 Subject: [PATCH] Fix crash when imported CSV has invalid syntax (#5702) --- src/pretix/control/views/modelimport.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pretix/control/views/modelimport.py b/src/pretix/control/views/modelimport.py index fc0b90e883..9d3ed57953 100644 --- a/src/pretix/control/views/modelimport.py +++ b/src/pretix/control/views/modelimport.py @@ -156,7 +156,7 @@ class BaseProcessView(AsyncAction, FormView): ) ) reader = parse_csv(self.file.file, 1024 * 1024, "replace", charset=charset) - if reader._had_duplicates: + if reader and reader._had_duplicates: messages.warning( self.request, _(