mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
MDL-59011 restore: Check for userride only for activity events
This commit is contained in:
parent
17fb1d84a2
commit
23cef8753b
1 changed files with 3 additions and 2 deletions
|
@ -2658,8 +2658,9 @@ class restore_calendarevents_structure_step extends restore_structure_step {
|
||||||
$isuseroverride = !$data->courseid && $data->modulename && $data->instance;
|
$isuseroverride = !$data->courseid && $data->modulename && $data->instance;
|
||||||
|
|
||||||
// If we don't want to include user data and this record is a user override event
|
// If we don't want to include user data and this record is a user override event
|
||||||
// for an activity then we should not create it.
|
// for an activity then we should not create it. (Only activity events can be user override events - which must have this
|
||||||
if (!$this->task->get_setting_value('userinfo') && $isuseroverride) {
|
// setting).
|
||||||
|
if ($isuseroverride && $this->task->setting_exists('userinfo') && !$this->task->get_setting_value('userinfo')) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue