mirror of
https://github.com/django/django.git
synced 2024-12-25 10:35:48 +00:00
Fixed bug in [2531]. Thanks, Ned
git-svn-id: http://code.djangoproject.com/svn/django/trunk@2533 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
33c4e307f2
commit
401b83f172
@ -205,13 +205,13 @@ class RelatedObject(object):
|
|||||||
|
|
||||||
change = count - len(list)
|
change = count - len(list)
|
||||||
if change > 0:
|
if change > 0:
|
||||||
return list + [None] * len(change)
|
return list + [None] * change
|
||||||
if change < 0:
|
if change < 0:
|
||||||
return list[:change]
|
return list[:change]
|
||||||
else: # Just right
|
else: # Just right
|
||||||
return list
|
return list
|
||||||
else:
|
else:
|
||||||
return [None] * len(self.field.rel.num_in_admin)
|
return [None] * self.field.rel.num_in_admin
|
||||||
|
|
||||||
def editable_fields(self):
|
def editable_fields(self):
|
||||||
"Get the fields in this class that should be edited inline."
|
"Get the fields in this class that should be edited inline."
|
||||||
|
Loading…
Reference in New Issue
Block a user