Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed a subtle bug (really, an inconsistency) in ForeignKey that [813…

…2] 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
  • Loading branch information...
commit b69b15fe02c47a754ab117dd4b5957eabe05c1ca 1 parent bf77744
@jacobian jacobian authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  django/db/models/fields/related.py
View
2  django/db/models/fields/related.py
@@ -624,7 +624,7 @@ def __init__(self, to, to_field=None, rel_class=ManyToOneRel, **kwargs):
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

0 comments on commit b69b15f

Please sign in to comment.
Something went wrong with that request. Please try again.