|
@@ -64,7 +64,7 @@ class auth_plugin_macaroons extends auth_plugin_base {
|
64
|
64
|
}
|
65
|
65
|
|
66
|
66
|
function loginpage_hook() {
|
67
|
|
- global $DB, $login;
|
|
67
|
+ global $DB, $login, $CFG;
|
68
|
68
|
$message = "";
|
69
|
69
|
if(!empty($_COOKIE['das-macaroon'])) {
|
70
|
70
|
try {
|
|
@@ -85,9 +85,9 @@ class auth_plugin_macaroons extends auth_plugin_base {
|
85
|
85
|
$user->firstname = $name[0];
|
86
|
86
|
$user->lastname = $name[1];
|
87
|
87
|
$user->email = $login."@brendanabolivier.com";
|
88
|
|
- // var_dump($user);
|
89
|
88
|
$DB->update_record('user', $user);
|
90
|
89
|
complete_user_login($user);
|
|
90
|
+ redirect($CFG->wwwroot);
|
91
|
91
|
}
|
92
|
92
|
}
|
93
|
93
|
} catch(Exception $e) {
|