Merge pull request #500 from nextcloud/allow_custom_direct_login_displayname

Allow customer directlogin text
This commit is contained in:
Roeland Jago Douma 2021-01-12 15:24:59 +01:00 committed by GitHub
commit 0c43de541b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -492,9 +492,16 @@ class SAMLController extends Controller {
$attributes = ['loginUrls' => []];
if ($this->SAMLSettings->allowMultipleUserBackEnds()) {
$displayName = $this->l->t('Direct log in');
$customDisplayName = $this->config->getAppValue('user_saml', 'directLoginName', '');
if ($customDisplayName !== '') {
$displayName = $customDisplayName;
}
$attributes['loginUrls']['directLogin'] = [
'url' => $this->getDirectLoginUrl($redirectUrl),
'display-name' => $this->l->t('Direct log in')
'display-name' => $displayName,
];
}