MDL-23772 cleanup SESSION->wantsurl before redirect + removed unnecessary require_login()

This commit is contained in:
Petr Skoda 2010-10-03 15:27:31 +00:00
parent 375053ed10
commit 4613c1ea3d

View file

@ -57,7 +57,6 @@ if (!isloggedin() or isguestuser()) {
// do not require change own password cap if change forced
if (!get_user_preferences('auth_forcepasswordchange', false)) {
require_login();
require_capability('moodle/user:changeownpassword', $systemcontext);
}
@ -120,6 +119,7 @@ if ($mform->is_cancelled()) {
} else {
$returnto = $SESSION->wantsurl;
}
unset($SESSION->wantsurl);
notice($strpasswordchanged, $returnto);