Add username to LOCKOUT_TEMPLATE template context

So I can use their username in the lockout template, e.g. something like this,
This commit is contained in:
Dale O'Brien 2015-07-06 13:18:03 +10:00
parent 493184b3e7
commit 68f0d5ee86

View file

@ -340,6 +340,7 @@ def lockout_response(request):
context = {
'cooloff_time': COOLOFF_TIME,
'failure_limit': FAILURE_LIMIT,
'username': request.POST.get(USERNAME_FORM_FIELD, '')
}
return render_to_response(LOCKOUT_TEMPLATE, context,
context_instance=RequestContext(request))