mirror of
https://github.com/moodle/moodle.git
synced 2025-04-22 08:55:15 +02:00
MDL-82959 tool_recyclebin: Avoid null value for forcedsettings
This commit is contained in:
parent
13c12756b4
commit
91ce0739c2
@ -117,7 +117,7 @@ class category_bin extends base_bin {
|
||||
// This hack will be removed once recycle bin switches to use its own backup mode, with
|
||||
// own preferences and 100% separate from MOODLE_AUTOMATED.
|
||||
// TODO: Remove this as part of MDL-65228.
|
||||
$forcedbackupsettings = $CFG->forced_plugin_settings['backup'] ?? null;
|
||||
$forcedbackupsettings = $CFG->forced_plugin_settings['backup'] ?? [];
|
||||
$CFG->forced_plugin_settings['backup']['backup_auto_storage'] = 0;
|
||||
$CFG->forced_plugin_settings['backup']['backup_auto_files'] = 1;
|
||||
|
||||
@ -253,7 +253,7 @@ class category_bin extends base_bin {
|
||||
// This hack will be removed once recycle bin switches to use its own backup mode, with
|
||||
// own preferences and 100% separate from MOODLE_AUTOMATED.
|
||||
// TODO: Remove this as part of MDL-65228.
|
||||
$forcedrestoresettings = $CFG->forced_plugin_settings['restore'] ?? null;
|
||||
$forcedrestoresettings = $CFG->forced_plugin_settings['restore'] ?? [];
|
||||
$CFG->forced_plugin_settings['restore']['restore_general_users'] = 1;
|
||||
$CFG->forced_plugin_settings['restore']['restore_general_groups'] = 1;
|
||||
|
||||
|
@ -121,7 +121,7 @@ class course_bin extends base_bin {
|
||||
// This hack will be removed once recycle bin switches to use its own backup mode, with
|
||||
// own preferences and 100% separate from MOODLE_AUTOMATED.
|
||||
// TODO: Remove this as part of MDL-65228.
|
||||
$forcedbackupsettings = $CFG->forced_plugin_settings['backup'] ?? null;
|
||||
$forcedbackupsettings = $CFG->forced_plugin_settings['backup'] ?? [];
|
||||
$CFG->forced_plugin_settings['backup']['backup_auto_storage'] = 0;
|
||||
$CFG->forced_plugin_settings['backup']['backup_auto_files'] = 1;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user