mirror of
https://github.com/moodle/moodle.git
synced 2025-08-06 01:16:44 +02:00
MDL-39077 maxbytes - fix warnings for cli install
This commit is contained in:
parent
e7ff753cab
commit
c9c01f75b1
5 changed files with 19 additions and 7 deletions
|
@ -23,7 +23,11 @@ if ($hassiteconfig) { // speedup for non-admins, add all caps used on this page
|
|||
new lang_string('configprofileroles', 'admin'),
|
||||
array('student', 'teacher', 'editingteacher')));
|
||||
|
||||
$max_upload_choices = get_max_upload_sizes(0, 0, 0, $CFG->maxbytes);
|
||||
$maxbytes = 0;
|
||||
if (!empty($CFG->maxbytes)) {
|
||||
$maxbytes = $CFG->maxbytes;
|
||||
}
|
||||
$max_upload_choices = get_max_upload_sizes(0, 0, 0, $maxbytes);
|
||||
// maxbytes set to 0 will allow the maximum server limit for uploads
|
||||
$temp->add(new admin_setting_configselect('maxbytes', new lang_string('maxbytes', 'admin'), new lang_string('configmaxbytes', 'admin'), 0, $max_upload_choices));
|
||||
// 100MB
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue