From d3a30e43225cf857fbea1154051ac82d49992816 Mon Sep 17 00:00:00 2001
From: Lucas <lucas.roussel@ensiie.fr>
Date: Sun, 10 Dec 2017 23:35:07 +0100
Subject: [PATCH] update

---
 Projet/db.sqlite3                             | Bin 66560 -> 66560 bytes
 Projet/polls/__pycache__/views.cpython-35.pyc | Bin 10799 -> 10810 bytes
 Projet/polls/views.py                         |   6 +++---
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/Projet/db.sqlite3 b/Projet/db.sqlite3
index 5a8f6600885399a4ec9924154507dfcebce1e621..c11d7b2bfdf66646c83f09ecbacaa265cccb17de 100644
GIT binary patch
delta 81
zcmZqZU}@-JnIO&hV4{pO<AaR}b*>f`CKah==7~<`j+VhHi3WjbZe~Rp5&7nph1nrd
lx#`936@IP}Icdh}PR<#QDTT%c!O4Cug-))U#oS))1ps)?99sYY

delta 81
zcmZqZU}@-JnIO%0f1->t<Nb{Zb*>gc1{MB(g|1blB}P#yd1Yl8&N(3_!A|bwQN@*k
liSA)Vc|jEwrr||N1^QWeE?E_R-k}8%mHFA5#oS))1pvMH9-jaJ

diff --git a/Projet/polls/__pycache__/views.cpython-35.pyc b/Projet/polls/__pycache__/views.cpython-35.pyc
index 0268405a220cdd0e5da4fcfa1f8f81a967241633..8c2f6f8d801f01086645f9a86a85c983ba32276c 100644
GIT binary patch
delta 142
zcmZ1<vMYpBjF*=ybDM6|wvC)e<hZyP7#N%x7#NBVPQEUu#JG3zFF9%PN-KsE7KSWV
zhAcLQ6c&aWW`<@4##+|N`tnNb;d!nMjEszv1LbX5Bl8#;A~yHQ%QC7dFfcGMFtRc7
tGx9L<GV(GqGm0|uGIBBUF*1Whnb;V4n2J&+AC#4xe4Z&}vyI|s4geRP9V-9;

delta 98
zcmdlLvOa`UjF*>7c(ZQQmW`Z8<hWQE7#N%x7#NCoOujCs#JFYhFF9$c5*CImR)#D#
zh7=Zt8fJ!O2F6-eh8k9eqVmZ)@=B9K<!vY1%W!U9ATPqmC^uP7R*adEi)r%(g)B}0
D>arL{

diff --git a/Projet/polls/views.py b/Projet/polls/views.py
index 21cf423..d83426f 100644
--- a/Projet/polls/views.py
+++ b/Projet/polls/views.py
@@ -190,12 +190,12 @@ def manage_forgotten_passwd(request):
     if form.is_valid():
         mail = form.cleaned_data['mail']
         new = form.cleaned_data['new']
-        user = User.objects.get(email=mail)
-        if user:
+        try:
+            user = User.objects.get(email=mail)
             user.set_password(new)
             user.save()
             return HttpResponse("Votre nouveau mot de passe a bien été pris en compte")
-        else:
+        except:
             error = True
             template = loader.get_template('polls/forgotten_passwd.html')
             context = {
-- 
GitLab