Ticket #4571: django_newadmin_iterable.diff
File django_newadmin_iterable.diff, 916 bytes (added by , 17 years ago) |
---|
-
django/contrib/admin/sites.py
69 69 """ 70 70 admin_class = admin_class or ModelAdmin 71 71 # TODO: Handle options 72 if issubclass(model_or_iterable, Model):72 if type(model_or_iterable) not in (list, tuple): 73 73 model_or_iterable = [model_or_iterable] 74 74 for model in model_or_iterable: 75 75 if model in self._registry: … … 82 82 83 83 If a model isn't already registered, this will raise NotRegistered. 84 84 """ 85 if issubclass(model_or_iterable, Model):85 if type(model_or_iterable) not in (list, tuple): 86 86 model_or_iterable = [model_or_iterable] 87 87 for model in model_or_iterable: 88 88 if model not in self._registry: