mirror of
https://github.com/pretix/pretix.git
synced 2026-09-12 16:04:42 +00:00
Update src/pretix/base/forms/questions.py
Co-authored-by: pajowu <engelhardt@pretix.eu>
This commit is contained in:
@@ -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])
|
||||
|
||||
Reference in New Issue
Block a user