From f90449321b8cf69f567db49f81102751992fb7de Mon Sep 17 00:00:00 2001 From: Ramiro Morales Date: Sat, 30 Jul 2011 19:22:43 +0000 Subject: [PATCH] Simplified AdminSite self.name attribute initialization. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16576 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/contrib/admin/sites.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/django/contrib/admin/sites.py b/django/contrib/admin/sites.py index 1c6dba6b4d..49c1e7878c 100644 --- a/django/contrib/admin/sites.py +++ b/django/contrib/admin/sites.py @@ -39,12 +39,9 @@ class AdminSite(object): password_change_template = None password_change_done_template = None - def __init__(self, name=None, app_name='admin'): + def __init__(self, name='admin', app_name='admin'): self._registry = {} # model_class class -> admin_class instance - if name is None: - self.name = 'admin' - else: - self.name = name + self.name = name self.app_name = app_name self._actions = {'delete_selected': actions.delete_selected} self._global_actions = self._actions.copy()