Merge branch 'master' into dist/envole/6/master
This commit is contained in:
commit
ff9d07e0cb
|
@ -44,7 +44,6 @@ class SecurityController extends Controller
|
||||||
$attributes = \phpCAS::getAttributes();
|
$attributes = \phpCAS::getAttributes();
|
||||||
|
|
||||||
// Init
|
// Init
|
||||||
$username = "";
|
|
||||||
$email = "";
|
$email = "";
|
||||||
$lastname = "";
|
$lastname = "";
|
||||||
$firstname = "";
|
$firstname = "";
|
||||||
|
@ -63,9 +62,6 @@ class SecurityController extends Controller
|
||||||
if(isset($attributes[$this->getParameter('user_attr_cas_firstname')]))
|
if(isset($attributes[$this->getParameter('user_attr_cas_firstname')]))
|
||||||
$firstname = $attributes[$this->getParameter('user_attr_cas_firstname')];
|
$firstname = $attributes[$this->getParameter('user_attr_cas_firstname')];
|
||||||
|
|
||||||
// Cas nomail
|
|
||||||
if(empty($email)) $email = $username."@nomail.com";
|
|
||||||
|
|
||||||
$user = $em->getRepository('CadolesCoreBundle:User')->findOneBy(array("username"=>$username));
|
$user = $em->getRepository('CadolesCoreBundle:User')->findOneBy(array("username"=>$username));
|
||||||
$exists = $user ? true : false;
|
$exists = $user ? true : false;
|
||||||
|
|
||||||
|
@ -83,6 +79,8 @@ class SecurityController extends Controller
|
||||||
}
|
}
|
||||||
|
|
||||||
if($masteridentity=="SSO") {
|
if($masteridentity=="SSO") {
|
||||||
|
if(empty($email)) $email = $username."@nomail.com";
|
||||||
|
|
||||||
// Là c'est normal que potentiellement il n'existe pas il faut donc l'autogénérer
|
// Là c'est normal que potentiellement il n'existe pas il faut donc l'autogénérer
|
||||||
$user = new User();
|
$user = new User();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue