Fixed #628 -- Django no longer overwrites model class docstrings if they're provided

git-svn-id: http://code.djangoproject.com/svn/django/trunk@878 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Adrian Holovaty 2005-10-15 00:54:42 +00:00
parent 67e6252a1e
commit 8254a7a7db
1 changed files with 2 additions and 1 deletions

View File

@ -563,6 +563,7 @@ class ModelBase(type):
new_class = type.__new__(cls, name, bases, attrs)
# Give the class a docstring -- its definition.
if new_class.__doc__ is None:
new_class.__doc__ = "%s.%s(%s)" % (opts.module_name, name, ", ".join([f.name for f in opts.fields]))
# Create the standard, module-level API helper functions such