mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 08:56:36 +02:00
Small change, checking for file existence is arguably better this way.
This commit is contained in:
parent
c2f152ac21
commit
eceb9c5ce4
1 changed files with 1 additions and 1 deletions
|
@ -942,7 +942,7 @@ function blocks_get_config_default ($cformat='') {
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$format_config = $CFG->dirroot.'/course/format/'.$cformat.'/config.php';
|
$format_config = $CFG->dirroot.'/course/format/'.$cformat.'/config.php';
|
||||||
if (file_exists($format_config)) {
|
if (@is_file($format_config) && is_readable($format_config)) {
|
||||||
require($format_config);
|
require($format_config);
|
||||||
}
|
}
|
||||||
if (!empty($format['defaultblocks'])) {
|
if (!empty($format['defaultblocks'])) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue