reg/views.py
changeset 52 0cd75815847d
parent 51 08da9bd64fca
child 54 345d4413b85c
equal deleted inserted replaced
51:08da9bd64fca 52:0cd75815847d
   238     """ check for the password and then set the new password.
   238     """ check for the password and then set the new password.
   239     """
   239     """
   240 
   240 
   241     user = request.user
   241     user = request.user
   242     if not user.is_authenticated():
   242     if not user.is_authenticated():
   243         return redirect('/reg')
   243         raise Http404
   244 
   244 
   245     if request.method == "POST":
   245     if request.method == "POST":
   246         data = request.POST.copy()
   246         data = request.POST.copy()
   247         data.__setitem__('username', user.username)
   247         data.__setitem__('username', user.username)
   248         form = reg_forms.PasswordChangeForm(data)
   248         form = reg_forms.PasswordChangeForm(data)