Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'w02_MDL-30717_m21_usercreated' of git://github.com/skod…

…ak/moodle into MOODLE_21_STABLE
  • Loading branch information...
commit b48d180e396e2fe326f82f05c47bdc14e7bf371c 2 parents 86e84df + b4e0cd3
@samhemelryk samhemelryk authored
Showing with 3 additions and 1 deletion.
  1. +3 −1 lib/moodlelib.php
View
4 lib/moodlelib.php
@@ -3298,7 +3298,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);
@@ -3361,6 +3362,7 @@ function update_user_record($username) {
}
if ($newuser) {
$newuser['id'] = $oldinfo->id;
+ $newuser['timemodified'] = time();
$DB->update_record('user', $newuser);
// fetch full user record for the event, the complete user data contains too much info
// and we want to be consistent with other places that trigger this event
Please sign in to comment.
Something went wrong with that request. Please try again.