mirror of
https://github.com/django/django.git
synced 2025-10-24 22:26:08 +00:00
Fixed #9171 -- Fixed a few places where we were assuming lists instead of
generic sequences in ModelForm structures. Patch from mrmachine. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9086 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
@@ -528,6 +528,7 @@ def inlineformset_factory(parent_model, model, form=ModelForm,
|
||||
if fk.unique:
|
||||
max_num = 1
|
||||
if exclude is not None:
|
||||
exclude = list(exclude)
|
||||
exclude.append(fk.name)
|
||||
else:
|
||||
exclude = [fk.name]
|
||||
|
||||
Reference in New Issue
Block a user