MDL-30717 add missing time created info in create_user_record()

Credit goes to Luis Gustavo Mueller de Alcantara.
This commit is contained in:
Petr Skoda 2011-12-27 15:34:32 +01:00
parent a1d246334b
commit 17330e8aae

View file

@ -3607,7 +3607,8 @@ function create_user_record($username, $password, $auth = 'manual') {
}
$newuser->confirmed = 1;
$newuser->lastip = getremoteaddr();
$newuser->timemodified = time();
$newuser->timecreated = time();
$newuser->timemodified = $newuser->timecreated;
$newuser->mnethostid = $CFG->mnet_localhost_id;
$newuser->id = $DB->insert_record('user', $newuser);