Fixed error when log in as admin with saml login method.
This commit is contained in:
parent
902c5371f9
commit
497e56510a
|
@ -288,16 +288,11 @@ if (! isset ($config['id_user'])) {
|
|||
$nick_in_db = $_SESSION["prepared_login_da"]['id_user'];
|
||||
$expired_pass = false;
|
||||
}
|
||||
else if (($config['auth'] == 'saml') && $login_button_saml) {
|
||||
if (is_user_admin($nick)) {
|
||||
$nick_in_db = $nick;
|
||||
}
|
||||
else {
|
||||
else if (($config['auth'] == 'saml') && $login_button_saml && !is_user_admin($nick)) {
|
||||
include_once(ENTERPRISE_DIR . "/include/auth/saml.php");
|
||||
$saml_user_id = saml_process_user_login();
|
||||
$nick_in_db = $saml_user_id;
|
||||
}
|
||||
}
|
||||
else {
|
||||
// process_user_login is a virtual function which should be defined in each auth file.
|
||||
// It accepts username and password. The rest should be internal to the auth file.
|
||||
|
|
Loading…
Reference in New Issue