backends: fix choosing between official and personnal at account creation

This commit is contained in:
Benjamin Dauvergne 2013-07-24 22:37:23 +02:00
parent c9df303e95
commit a22d107ae7
2 changed files with 3 additions and 3 deletions

View File

@ -1,4 +1,4 @@
VERSION=0.13
VERSION=0.14
package:
git archive -o ../appli-logement-$(VERSION).tar --prefix=appli-logement-$(VERSION)/ HEAD

View File

@ -125,8 +125,8 @@ class ProfilRechercheAuthentification(ProfilMoteurAuthentification):
'''Création de compte depuis le LDAP
'''
email = ldap_resultat[0][1].get(self.MAIL)
email |= ldap_resultat[0][1].get(self.SUPANN_MAIL_PERSO)
email |= ''
email = email or ldap_resultat[0][1].get(self.SUPANN_MAIL_PERSO)
email = email or ''
return self.profil_classe.new_cas_user(identifiant, email, cas_url)
def creation_automatique_du_compte(self, identifiant, cas_url, ldap_resultat):