mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
Not having any users in a backup is not necessarily an error.
This commit is contained in:
parent
8c02baf617
commit
e23defdb12
1 changed files with 2 additions and 4 deletions
|
@ -487,8 +487,8 @@
|
||||||
//Now, get evey user_id from $info and user data from $backup_ids
|
//Now, get evey user_id from $info and user data from $backup_ids
|
||||||
//and create the necessary records (users, user_students, user_teachers
|
//and create the necessary records (users, user_students, user_teachers
|
||||||
//user_course_creators and user_admins
|
//user_course_creators and user_admins
|
||||||
if ($info) {
|
if (!empty($info->users)) {
|
||||||
//For each, user, take its info from backup_ids
|
//For each user, take its info from backup_ids
|
||||||
foreach ($info->users as $userid) {
|
foreach ($info->users as $userid) {
|
||||||
$rec = backup_getid($restore->backup_unique_code,"user",$userid);
|
$rec = backup_getid($restore->backup_unique_code,"user",$userid);
|
||||||
$user = $rec->info;
|
$user = $rec->info;
|
||||||
|
@ -625,8 +625,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
$status = false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return $status;
|
return $status;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue