Conver usernames to lowercase for internal use. This prevent duplicate users

when using external authentication and posgresql.
This commit is contained in:
paca70
2003-04-24 20:06:40 +00:00
parent e40488f80c
commit 1e22bc9c04
4 changed files with 14 additions and 12 deletions
+2 -1
View File
@@ -489,7 +489,8 @@ function get_moodle_cookie() {
function create_user_record($username, $password) {
/// Creates a bare-bones user record
global $REMOTE_ADDR, $CFG;
//just in case check text case
$username = trim(moodle_strtolower($username));
if (function_exists(auth_get_userinfo)) {
if ($newinfo = auth_get_userinfo($username)) {
foreach ($newinfo as $key => $value){