Skip to content

Commit

Permalink
fix: variable $ldap_user has not been initialized
Browse files Browse the repository at this point in the history
  • Loading branch information
AppChecker committed Jan 30, 2016
1 parent d82f2d6 commit 5cf49b5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions main/auth/cas/authcas.php
Expand Up @@ -88,7 +88,7 @@ function cas_is_authenticated()
// if option is on we update user automatically from ldap server
if (api_get_setting("update_user_info_cas_with_ldap") == "true") {
$ldapuser = extldap_authenticate($login, 'nopass', true);
if ($ldap_user !== false) {
if ($ldapuser !== false) {
$chamilo_user = extldap_get_chamilo_user($ldapuser);
$chamilo_user['user_id'] = $tab_user_info['user_id'];
$chamilo_user['status'] = $tab_user_info['status'];
Expand All @@ -114,7 +114,7 @@ function cas_is_authenticated()
// user has already been authenticated by CAS
// If user not found in LDAP, user not created
$ldapuser = extldap_authenticate($login, 'nopass', true);
if ($ldap_user !== false) {
if ($ldapuser !== false) {
$chamilo_user = extldap_get_chamilo_user($ldapuser);
$chamilo_user['username'] = $login;
$chamilo_user['auth_source'] = CAS_AUTH_SOURCE;
Expand Down

0 comments on commit 5cf49b5

Please sign in to comment.