mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 17:06:53 +02:00
MDL-51250 course: No function returns in empty()
This commit is contained in:
parent
05e6215c48
commit
d1583d8e9c
1 changed files with 2 additions and 1 deletions
|
@ -112,7 +112,8 @@ class editsection_form extends moodleform {
|
||||||
$data = parent::get_data();
|
$data = parent::get_data();
|
||||||
if ($data !== null) {
|
if ($data !== null) {
|
||||||
$editoroptions = $this->_customdata['editoroptions'];
|
$editoroptions = $this->_customdata['editoroptions'];
|
||||||
if (!empty($data->usedefaultname) || empty(trim($data->name))) {
|
$trimmedname = $data->name;
|
||||||
|
if (!empty($data->usedefaultname) || empty($trimmedname)) {
|
||||||
$data->name = null;
|
$data->name = null;
|
||||||
}
|
}
|
||||||
$data = file_postupdate_standard_editor($data, 'summary', $editoroptions,
|
$data = file_postupdate_standard_editor($data, 'summary', $editoroptions,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue