mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-29 00:34:03 +02:00
Revert "Util\Translator: show correct language list"
This reverts commit b7521f48b960d27c1600aab5e79cf90d34ef8b68.
This commit is contained in:
parent
40a3c0d19b
commit
20cdb6e0b8
@ -133,19 +133,10 @@ class Translator
|
||||
$codes = array();
|
||||
|
||||
foreach (array_values(self::$knownDomains) as $directory) {
|
||||
if ($directory[0] === '.') continue;
|
||||
|
||||
$dir = realpath($directory);
|
||||
if (!is_dir($dir)) {
|
||||
$dir = realpath($dir . '/LC_MESSAGES');
|
||||
if (!is_dir($dir)) continue;
|
||||
}
|
||||
$dh = opendir($dir);
|
||||
$dh = opendir($directory);
|
||||
while (false !== ($name = readdir($dh))) {
|
||||
if (substr($name, 0, 1) === '.') continue;
|
||||
if ($name === 'LC_MESSAGES') continue;
|
||||
if (is_dir($dir . DIRECTORY_SEPARATOR . $name)) {
|
||||
$codes[] = substr($name, 0, strpos($name, '.'));
|
||||
if (!preg_match('@\.|\.\.@', $name) && is_dir($directory . DIRECTORY_SEPARATOR . $name)) {
|
||||
$codes[] = $name;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user