mirror of
https://github.com/django/django.git
synced 2024-12-24 10:05:46 +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)
|
||||
if change > 0:
|
||||
return list + [None] * len(change)
|
||||
return list + [None] * change
|
||||
if change < 0:
|
||||
return list[:change]
|
||||
else: # Just right
|
||||
return list
|
||||
else:
|
||||
return [None] * len(self.field.rel.num_in_admin)
|
||||
return [None] * self.field.rel.num_in_admin
|
||||
|
||||
def editable_fields(self):
|
||||
"Get the fields in this class that should be edited inline."
|
||||
|
Loading…
Reference in New Issue
Block a user