Skip to content

Commit

Permalink
Set default for option_auto_record for older restores
Browse files Browse the repository at this point in the history
  • Loading branch information
smbader committed Mar 16, 2023
1 parent 3c29fca commit 1b98f3f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions backup/moodle2/restore_zoom_stepslib.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ protected function process_zoom($data) {
$data->join_url = '';
$data->meeting_id = 0;
$data->exists_on_zoom = ZOOM_MEETING_EXPIRED;
$data->option_auto_recording = 'none';
}

$data->course = $this->get_courseid();
Expand Down
3 changes: 3 additions & 0 deletions lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,9 @@ function populate_zoom_from_response(stdClass $zoom, stdClass $response) {
if (isset($response->settings->auto_recording)) {
$newzoom->option_auto_recording = $response->settings->auto_recording;
}
if (!isset($newzoom->option_auto_recording)) {
$newzoom->option_auto_recording = 'none';
}

return $newzoom;
}
Expand Down

0 comments on commit 1b98f3f

Please sign in to comment.