equal
deleted
inserted
replaced
222 form = reg_forms.PasswordResetForm(request.POST) |
222 form = reg_forms.PasswordResetForm(request.POST) |
223 if form.is_valid(): |
223 if form.is_valid(): |
224 email = form.cleaned_data['email'] |
224 email = form.cleaned_data['email'] |
225 user = User.objects.get(email__iexact=email) |
225 user = User.objects.get(email__iexact=email) |
226 new_password = reg_events.reset_password(user) |
226 new_password = reg_events.reset_password(user) |
227 reg_events.mail_password(user, new_password) |
|
228 return render_to_response('password_reset.html', {'user':user, 'new_password':new_password}) |
227 return render_to_response('password_reset.html', {'user':user, 'new_password':new_password}) |
229 else: |
228 else: |
230 return render_to_response('password_reset.html', {'user':user, 'form':form}) |
229 return render_to_response('password_reset.html', {'user':user, 'form':form}) |
231 else: |
230 else: |
232 form = reg_forms.PasswordResetForm() |
231 form = reg_forms.PasswordResetForm() |