#4571 closed (fixed)
small patch for multi model admin.site registering
Reported by: | Jakub Vysoky [kvbik] | Owned by: | Adrian Holovaty |
---|---|---|---|
Component: | contrib.admin | Version: | newforms-admin |
Severity: | Keywords: | issubclass model_or_iterable | |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
the code bellow:
from django.contrib import admin admin.site.register([Model1, Model2], SomeAdminClass)
would cause error:
proj.app: issubclass() arg 1 must be a class
when calling issubclass(model_or_iterable, Model),
it would complain that model_or_iterable is not class (because it's instance of list).
Attachments (1)
Change History (3)
by , 17 years ago
Attachment: | django_newadmin_iterable.diff added |
---|
comment:1 by , 17 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
issubclass => is not tuple or list