Skip to content
Browse files

Faster logging in, better redirection

  • Loading branch information...
1 parent 4a74e32 commit 1a2363de28f51d628f5f5afcddff075e99471053 @thedjpetersen committed Jun 13, 2011
Showing with 2 additions and 2 deletions.
  1. +2 −2 main/views.py
View
4 main/views.py
@@ -14,13 +14,13 @@ def login(request):
if 'regclass' in request.session:
return HttpResponseRedirect('/main')
if request.method == 'GET':
- return render_to_response('index.html')
+ return HttpResponseRedirect('/')
username = request.POST['username']
password = request.POST['password']
try:
- regclass = reglib.infosu(username, password)
+ regclass = reglib.infosu(username, password, True)
request.session['regclass'] = regclass
request.session.set_expiry(1200)
return HttpResponseRedirect('/main')

0 comments on commit 1a2363d

Please sign in to comment.
Something went wrong with that request. Please try again.