﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
15585	Login view should call an empty hook in the authentication form	freyley	nobody	"In django.contrib.auth.views.login, it'd be really nice if this:

            # Okay, security checks complete. Log the user in.
            auth_login(request, form.get_user())

            if request.session.test_cookie_worked():
                request.session.delete_test_cookie()
            
            return HttpResponseRedirect(redirect_to)

were changed to this:

            # Okay, security checks complete. Log the user in.
            auth_login(request, form.get_user())

            form.after_login_hook(request)   
             
            if request.session.test_cookie_worked():
                request.session.delete_test_cookie()
            
            return HttpResponseRedirect(redirect_to)

(and, django.contrib.auth.forms.AuthenticationForm, add 

def after_login_hook(self, request):
    pass

)

To allow for people who want to affect the session after login. The use case I just wanted it for is is adding a ""remember me"" checkbox. I can add it to the form easily enough, but since the form doesn't have access to the session, I also have to duplicate the view."		closed	contrib.auth	1.2		wontfix			Unreviewed	1	0	0	0	0	0
