Skip to content

Commit

Permalink
Merge pull request #103 from catalyst/unsuspend-email
Browse files Browse the repository at this point in the history
Fix incorrect assumption about username based on email
  • Loading branch information
keevan authored Sep 7, 2022
2 parents 4b7911e + d14d016 commit 9a251b5
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 5 deletions.
5 changes: 0 additions & 5 deletions classes/utility.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,6 @@ public static function search_for_suspended_user($data) {
$params['username'] = $data['username'];
}

// This setting means the email address is the username.
if ($CFG->createuserwithemail) {
$params['username'] = $data['email'];
}

return $DB->get_record('user', $params, '*');
}

Expand Down
1 change: 1 addition & 0 deletions unsuspend.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
$PAGE->set_pagelayout('login');
$PAGE->set_title(get_string('title_unsuspend', 'auth_enrolkey'));
$PAGE->set_heading(get_string('heading_unsuspend', 'auth_enrolkey'));
$PAGE->set_context($context);
$output = $PAGE->get_renderer('auth_enrolkey');

$form = new unsuspend_form($baseurl);
Expand Down

0 comments on commit 9a251b5

Please sign in to comment.