Merge branch 'MDL-54755_moodle30' of https://github.com/StudiUM/moodle into MOODLE_30_STABLE

This commit is contained in:
Andrew Nicols
2016-06-28 10:01:55 +08:00
3 changed files with 119 additions and 1 deletions
+2 -1
View File
@@ -4284,7 +4284,7 @@ function authenticate_user_login($username, $password, $ignorelockout=false, &$f
* @return stdClass A {@link $USER} object - BC only, do not use
*/
function complete_user_login($user) {
global $CFG, $USER;
global $CFG, $USER, $SESSION;
\core\session\manager::login_user($user);
@@ -4327,6 +4327,7 @@ function complete_user_login($user) {
if ($changeurl = $userauth->change_password_url()) {
redirect($changeurl);
} else {
$SESSION->wantsurl = core_login_get_return_url();
redirect($CFG->httpswwwroot.'/login/change_password.php');
}
} else {