Closed
Description
Running existing projects gives the following error:
/multiselectfield/forms/fields.py", line 30, in __init__
self.flat_choices = kwargs.pop('flat_choices')
KeyError: 'flat_choices'
My form classes look like this
class MyForm(forms.Form):
CHOICES = (
('a', 'A'),
('b', 'B'),
)
reason = MultiSelectFormField(choices=CHOICES, widget=forms.CheckboxSelectMultiple, required=False)
In #118 (diff ref) MultiSelectFormField now requires a flat_choices
field - isn't this the same as the inherited choices
attribute?
Adding flat_choices=CHOICES
fixes the issue but it would be nice to know if this change was intended or if its purpose could be documented (I appreciate the original PR is years old so this might not be known!)
PS thanks for the recent activity! <3
Metadata
Metadata
Assignees
Labels
No labels