mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
MDL-24848 prevent undefined docs url problems in install
This commit is contained in:
parent
14a0e7ddff
commit
8260ca36d5
@ -2786,7 +2786,11 @@ function convert_tabrows_to_tree($tabrows, $selected, $inactive, $activated) {
|
||||
*/
|
||||
function get_docs_url($path) {
|
||||
global $CFG;
|
||||
return $CFG->docroot . '/' . current_language() . '/' . $path;
|
||||
if (!empty($CFG->docroot)) {
|
||||
return $CFG->docroot . '/' . current_language() . '/' . $path;
|
||||
} else {
|
||||
return 'http://docs.moodle.org/en/'.$path;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user