Commit eb20a62c authored by Aaron Wells's avatar Aaron Wells

More robust handling of lang directory search problems

Bug 1067724

Change-Id: Ie3f6b1136307e4c715929e94d6892e43636c7baf
parent f0b7b6ed
......@@ -589,7 +589,12 @@ function language_get_searchpaths() {
$docrootpath = array(get_config('docroot'));
// Paths to language files in dataroot
$datarootpaths = (array)glob(get_config('dataroot') . 'langpacks/*', GLOB_MARK | GLOB_ONLYDIR);
$datarootbase = get_config('dataroot') . 'langpacks/*';
$datarootpaths = glob($datarootbase, GLOB_MARK | GLOB_ONLYDIR);
if ($datarootpaths === false) {
log_warn("Problem searching for langfiles at this path: " . $datarootbase);
$datarootpaths = array();
}
// langpacksearchpaths configuration variable - for experts :)
$lpsearchpaths = (array)get_config('langpacksearchpaths');
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment