mirror of
https://github.com/moodle/moodle.git
synced 2025-08-07 18:06:51 +02:00
Merge branch 'w12_MDL-31703_m23_rootdirroot' of git://github.com/skodak/moodle
This commit is contained in:
commit
2cd97ff3c5
1 changed files with 5 additions and 1 deletions
|
@ -46,7 +46,11 @@ foreach ($files as $fsfile) {
|
||||||
// does not exist
|
// does not exist
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (strpos($jsfile, $CFG->dirroot . DIRECTORY_SEPARATOR) !== 0) {
|
if ($CFG->dirroot === '/') {
|
||||||
|
// Some shared hosting sites serve files directly from '/',
|
||||||
|
// this is NOT supported, but at least allow JS when showing
|
||||||
|
// errors and warnings.
|
||||||
|
} else if (strpos($jsfile, $CFG->dirroot . DIRECTORY_SEPARATOR) !== 0) {
|
||||||
// hackers - not in dirroot
|
// hackers - not in dirroot
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue