Update src/pretix/base/forms/questions.py

Co-authored-by: pajowu <engelhardt@pretix.eu>
This commit is contained in:
Raphael Michel
2026-09-11 18:36:04 +02:00
committed by GitHub
co-authored by pajowu
parent 5be4719ac1
commit 81e4b0ec55
+1
View File
@@ -350,6 +350,7 @@ class WrappedPhonePrefixSelect(Select):
return super().render(name, value or self.initial, *args, **kwargs)
def get_context(self, name, value, attrs):
# self.choices is lazy evaluated, needs to be realized to be modifiable
choices = list(self.choices)
if value and choices[1][0] != value:
matching_choices = len([1 for p, c in choices if p == value])