Commit d739e308 authored by Richard Mansfield's avatar Richard Mansfield

Don't try to restore from logged-in-as user after session timeout

parent edba66f3
......@@ -27,6 +27,10 @@
define('INTERNAL', 1);
require(dirname(dirname(dirname(__FILE__))) . '/init.php');
if (param_integer('login_submitted', 0)) {
redirect(get_config('wwwroot'));
}
if (param_integer('restore', 0)) {
$id = $USER->restore_identity();
redirect(get_config('wwwroot') . 'admin/users/edit.php?id=' . $id);
......
......@@ -942,6 +942,10 @@ function auth_get_login_form() {
'type' => 'submit',
'value' => get_string('login')
),
'login_submitted' => array(
'type' => 'hidden',
'value' => 1
),
);
// The login page is completely transient, and it is smart because it
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment