Initial support for SAML authentication
This commit is contained in:
@@ -143,6 +143,15 @@ module.exports = function (sequelize, DataTypes) {
|
||||
photo = letterAvatars(profile.username)
|
||||
}
|
||||
break
|
||||
case 'saml':
|
||||
if (profile.emails[0]) {
|
||||
photo = 'https://www.gravatar.com/avatar/' + md5(profile.emails[0])
|
||||
if (bigger) photo += '?s=400'
|
||||
else photo += '?s=96'
|
||||
} else {
|
||||
photo = letterAvatars(profile.username)
|
||||
}
|
||||
break
|
||||
}
|
||||
return photo
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user