-
Bug
-
Resolution: Fixed
-
Blocker
-
2.6
-
MOODLE_26_STABLE
-
MOODLE_26_STABLE
-
w01_
MDL-43585_m27_userlib -
-
BACKEND Sprint 9
Since upgrading to 2.6, when a new user clicks the registration confirmation link in the email, the confirm.php generates a 500 Internal server error and fails to activate the user.
The Apache error log contains:
PHP Fatal error: require_once(): Failed opening required '/user/lib.php' (include_path='/var/www/html/moodle-2.6/lib/zend:/var/www/html/moodle-2.6/lib/pear:.:/usr/share/pear:/usr/share/php') in /var/www/html/moodle-2.6/auth/ldap/auth.php on line 619
Line 619 of auth/ldap/auth.php contains:
require_once($CFG->dirroot.'/user/lib.php');
It seems that $CFG is not accessible in the "user_confirm" function's context.
Prior to 2.6, the user_confirm function didn't require any other librairies.
My quick workaround for tomorrow morning:
Hardcode the /usr/lib.php filesystem path at line 619, the confirmation process now works correctly.