Skip to content

Commit

Permalink
remove setting 'enrolments', it is the wrong setting (sets how users …
Browse files Browse the repository at this point in the history
…stored in the mbz are handled, not how users can enrol after restore)
  • Loading branch information
Glutamat42 committed Jul 19, 2024
1 parent bc72193 commit c818a42
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions classes/external/upload_course.php
Original file line number Diff line number Diff line change
Expand Up @@ -133,11 +133,6 @@ public static function execute(int $category_id=null, bool $only_check_permissio
backup::TARGET_NEW_COURSE
);

// do restore: set required enrolment setting
// TODO: is correctly stored in mbz (status 0 means active). So this is not required, instead configure it to apply enrolment settings
$plan = $controller->get_plan();
$plan->get_tasks()[0]->get_setting('enrolments')->set_value(backup::ENROL_ALWAYS);

// do restore: execute
$controller->execute_precheck();
$controller->execute_plan();
Expand Down

0 comments on commit c818a42

Please sign in to comment.