locale cache: fix a bug when perms are done wrong

This commit is contained in:
czaks 2016-05-05 08:43:34 +02:00
parent 36b78e5f98
commit a42256b296

View File

@ -127,7 +127,7 @@ function loadConfig() {
// So, we may store the locale in a tmp/ filesystem.
if (file_exists($fn = 'tmp/cache/locale_' . $boardsuffix ) ) {
$config['locale'] = file_get_contents($fn);
$config['locale'] = @file_get_contents($fn);
}
else {
$config['locale'] = 'en';
@ -144,7 +144,7 @@ function loadConfig() {
$config['locale'] = $matches[count($matches)-1];
}
file_put_contents($fn, $config['locale']);
@file_put_contents($fn, $config['locale']);
}
if ($config['locale'] != $current_locale) {