Skip to content
Snippets Groups Projects
Commit 377e18e4 authored by Sonia Zorba's avatar Sonia Zorba
Browse files

ShibbolethLogin: made name and surname optional

parent 93cf9291
No related branches found
No related tags found
No related merge requests found
...@@ -22,8 +22,12 @@ class ShibbolethLogin extends LoginHandler { ...@@ -22,8 +22,12 @@ class ShibbolethLogin extends LoginHandler {
return $this->onIdentityDataReceived($eppn, function($identity) use($eppn) { return $this->onIdentityDataReceived($eppn, function($identity) use($eppn) {
$identity->email = $_SERVER['mail']; $identity->email = $_SERVER['mail'];
if (isset($_SERVER['givenName'])) {
$identity->name = $_SERVER['givenName']; $identity->name = $_SERVER['givenName'];
}
if (isset($_SERVER['sn'])) {
$identity->surname = $_SERVER['sn']; $identity->surname = $_SERVER['sn'];
}
$identity->eppn = $eppn; $identity->eppn = $eppn;
}); });
} else { } else {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment