Skip to content

Commit

Permalink
fix: use first email address when retrieving multiple from LDAP (#2051)
Browse files Browse the repository at this point in the history
Signed-off-by: Jonas Jöst <jonas@gpplanet.de>
  • Loading branch information
jonasjoest authored Jun 16, 2020
1 parent 9e08718 commit 3b055f2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/modules/authentication/ldap/authentication.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ module.exports = {
const user = await WIKI.models.users.processProfile({
profile: {
id: userId,
email: _.get(profile, conf.mappingEmail, ''),
email: String(_.get(profile, conf.mappingEmail, '')).split(',')[0],
displayName: _.get(profile, conf.mappingDisplayName, '???'),
picture: _.get(profile, conf.mappingPicture, '')
},
Expand Down

0 comments on commit 3b055f2

Please sign in to comment.