Ticket #2833: auth_context_processors_fix.diff

File auth_context_processors_fix.diff, 469 bytes (added by deepak <deep.thukral@…>, 17 years ago)
  • context_processors.py

     
    1414    Returns context variables required by apps that use Django's authentication
    1515    system.
    1616    """
     17    if not hasattr(request, 'user'):
     18        return {}
    1719    return {
    1820        'user': request.user,
    1921        'messages': request.user.get_and_delete_messages(),
Back to Top