mirror of
https://github.com/moodle/moodle.git
synced 2025-04-21 00:12:56 +02:00
MDL-82349 core_courseformat: fix home section zero name
This commit is contained in:
parent
2b337b49f9
commit
c6a9177252
@ -58,9 +58,12 @@ class format_site extends course_format {
|
||||
if ((string)$section->name !== '') {
|
||||
// Return the name the user set.
|
||||
return format_string($section->name, true, array('context' => context_course::instance($this->courseid)));
|
||||
} else {
|
||||
return get_string('site');
|
||||
}
|
||||
// The section zero is located in a block.
|
||||
if ($section->sectionnum == 0) {
|
||||
return get_string('block');
|
||||
}
|
||||
return get_string('site');
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user