Skip to content

Commit

Permalink
MDL-35773 core_backup: removed introduction of 'set_mode'
Browse files Browse the repository at this point in the history
  • Loading branch information
mdjnelson committed Jul 26, 2019
1 parent 94c7105 commit 8e83e54
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 15 deletions.
1 change: 0 additions & 1 deletion backup/backup.php
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,6 @@
// Before we perform the backup check settings to see if user
// or setting defaults are set to exclude files from the backup.
if ($backup->get_setting_value('files') == 0) {
$bc->set_mode(backup::MODE_SAMESITE);
$renderer->set_samesite_notification();
}

Expand Down
14 changes: 0 additions & 14 deletions backup/controller/backup_controller.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -185,20 +185,6 @@ public function process_ui_event() {
backup_check::check_security($this, false);
}

/**
* Sets the mode (purpose) of the backup.
*
* @param int $mode The mode to set.
*/
public function set_mode($mode) {
$this->mode = $mode;
$this->set_include_files(); // Need to check if files are included as mode may have changed.
$this->save_controller();
$tbc = self::load_controller($this->backupid);
$this->logger = $tbc->logger; // Wakeup loggers.
$tbc->plan->destroy(); // Clean plan controller structures, keeping logger alive.
}

public function set_status($status) {
// Note: never save_controller() with the object info after STATUS_EXECUTING or the whole controller,
// containing all the steps will be sent to DB. 100% (monster) useless.
Expand Down

0 comments on commit 8e83e54

Please sign in to comment.