Kill another unneeded translation

We should only translate things when we actually need them.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
Roeland Jago Douma 2020-07-08 21:47:16 +02:00
parent ce5cb5ac33
commit c7d9636e82
No known key found for this signature in database
GPG Key ID: F941078878347C0C
1 changed files with 5 additions and 7 deletions

View File

@ -998,23 +998,21 @@ class OC_Util {
if (\OC::$server->getConfig()->getSystemValue('check_data_directory_permissions', true) === false) {
return [];
}
$l = \OC::$server->getL10N('lib');
$errors = [];
$permissionsModHint = $l->t('Please change the permissions to 0770 so that the directory'
. ' cannot be listed by other users.');
$perms = substr(decoct(@fileperms($dataDirectory)), -3);
if (substr($perms, -1) !== '0') {
chmod($dataDirectory, 0770);
clearstatcache();
$perms = substr(decoct(@fileperms($dataDirectory)), -3);
if ($perms[2] !== '0') {
$errors[] = [
$l = \OC::$server->getL10N('lib');
return [
'error' => $l->t('Your data directory is readable by other users'),
'hint' => $permissionsModHint
'hint' => $l->t('Please change the permissions to 0770 so that the directory cannot be listed by other users.'),
];
}
}
return $errors;
return [];
}
/**