Commit eb57fbcc authored by Nigel McNie's avatar Nigel McNie
Browse files

Make sure we check for the correct langconfig.php, regardless of whether we're...

Make sure we check for the correct langconfig.php, regardless of whether we're retrieving a plugin string or not.

Fixes a gazillion warnings to the logs when using language packs other than English.
parent 99312793
......@@ -237,12 +237,12 @@ function get_helpfile_location($plugintype, $pluginname, $form, $element, $page=
// if it's not found, try the parent language if there is one...
if (empty($data) && empty($trieden)) {
$langfile = $location . $lang . '/langconfig.php';
$langfile = get_config('docroot') . 'lang/' . $lang . '/langconfig.php';
if ($parentlang = get_string_from_file('parentlanguage', $langfile)) {
if ($parentlang == 'en.utf8') {
$trieden = true;
}
$langfile = $location . $parentlang . '/' . $file;
$langfile = get_config('docroot') . 'lang/' . $parentlang . '/' . $file;
if (is_readable($langfile)) {
return $langfile;
}
......
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