diff options
| author | Adrian Holovaty <adrian@holovaty.com> | 2006-03-20 01:04:09 +0000 |
|---|---|---|
| committer | Adrian Holovaty <adrian@holovaty.com> | 2006-03-20 01:04:09 +0000 |
| commit | 401b83f172d6f2b0da6c67282bd1d93159c61204 (patch) | |
| tree | 592076a3bf4eb48e40fcbcd96b6dc61ce830944d | |
| parent | 33c4e307f24e4af52430550fd9e444d9add13201 (diff) | |
Fixed bug in [2531]. Thanks, Ned
git-svn-id: http://code.djangoproject.com/svn/django/trunk@2533 bcc190cf-cafb-0310-a4f2-bffc1f526a37
| -rw-r--r-- | django/core/meta/__init__.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/django/core/meta/__init__.py b/django/core/meta/__init__.py index b709e56341..3de7c44b68 100644 --- a/django/core/meta/__init__.py +++ b/django/core/meta/__init__.py @@ -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." |
