From b69b15fe02c47a754ab117dd4b5957eabe05c1ca Mon Sep 17 00:00:00 2001 From: Jacob Kaplan-Moss Date: Tue, 29 Jul 2008 18:31:27 +0000 Subject: [PATCH] Fixed a subtle bug (really, an inconsistency) in ForeignKey that [8132] exposed by causing the model_forms test to fail. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8138 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/db/models/fields/related.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/django/db/models/fields/related.py b/django/db/models/fields/related.py index 7f6b1c67c8..f73ac68f8d 100644 --- a/django/db/models/fields/related.py +++ b/django/db/models/fields/related.py @@ -624,7 +624,7 @@ class ForeignKey(RelatedField, Field): assert isinstance(to, basestring), "%s(%r) is invalid. First parameter to ForeignKey must be either a model, a model name, or the string %r" % (self.__class__.__name__, to, RECURSIVE_RELATIONSHIP_CONSTANT) else: to_field = to_field or to._meta.pk.name - kwargs['verbose_name'] = kwargs.get('verbose_name', '') + kwargs['verbose_name'] = kwargs.get('verbose_name', None) if 'edit_inline_type' in kwargs: import warnings