Ticket #3185: login_url.diff

File login_url.diff, 597 bytes (added by Vasily Sulatskov <redvasily@…>, 18 years ago)
  • django/contrib/auth/__init__.py

     
    11from django.core.exceptions import ImproperlyConfigured
    22
     3from django.conf import settings
     4
    35SESSION_KEY = '_auth_user_id'
    46BACKEND_SESSION_KEY = '_auth_user_backend'
    5 LOGIN_URL = '/accounts/login/'
     7
     8try:
     9    LOGIN_URL = settings.LOGIN_URL
     10except AttributeError:
     11    LOGIN_URL = '/accounts/login/'
     12
    613REDIRECT_FIELD_NAME = 'next'
    714
    815def load_backend(path):
Back to Top