Skip to content

Commit

Permalink
preferred_username as one of display name claim for OIDC
Browse files Browse the repository at this point in the history
  • Loading branch information
zorn-v committed Sep 17, 2019
1 parent 7dfa065 commit b291cbe
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion appinfo/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<name>Social Login</name>
<summary>Social login via OAuth or OpenID</summary>
<description> </description>
<version>2.1.1</version>
<version>2.1.2</version>
<licence>agpl</licence>
<author>zorn-v</author>
<namespace>SocialLogin</namespace>
Expand Down
2 changes: 1 addition & 1 deletion lib/Provider/CustomOpenIDConnect.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public function getUserProfile()

$userProfile = new User\Profile();
$userProfile->identifier = $data->get('sub');
$userProfile->displayName = $data->get('name');
$userProfile->displayName = $data->get('name') ?: $data->get('preferred_username');
$userProfile->photoURL = $data->get('picture');
$userProfile->email = $data->get('email');
if (null !== $groups = $this->getGroups($data)) {
Expand Down

0 comments on commit b291cbe

Please sign in to comment.