]> git.mjollnir.org Git - moodle.git/commitdiff
BUG FIX: In the last version I introduced a new security feature
authormartin <martin>
Thu, 5 Sep 2002 02:04:00 +0000 (02:04 +0000)
committermartin <martin>
Thu, 5 Sep 2002 02:04:00 +0000 (02:04 +0000)
(keeping the site URL stored in the USER session object) but forgot
to add this to the brand new admin user - causing it to fail.

Fixed.

admin/user.php

index d34c4d0b5715625108b68bf58cbef2dbe414a4b1..c4aa8145192c889fb61983ef9bc6947e85ad9b9f 100644 (file)
@@ -8,7 +8,7 @@
         $user->firstname = "Admin";
         $user->lastname  = "User";
         $user->username  = "admin";
-        $user->password  = "";
+        $user->password  = md5("admin");
         $user->email     = "root@localhost";
         $user->confirmed = 1;
         $user->maildisplay = 1;
@@ -41,6 +41,7 @@
 
         $USER = $user;
         $USER->loggedin = true;
+        $USER->site = $CFG->wwwroot;
         $USER->admin = true;
         $USER->teacher["$site->id"] = true;
         save_session("USER");