FEATURE: create directory for translations if not exist
This commit is contained in:
@@ -36,6 +36,10 @@ class Translations extends Command
|
||||
$defaultLocalesDir = $dir . '/' . $defaultLocales;
|
||||
$currentLocalesDir = $dir . '/' . $currentLocales;
|
||||
|
||||
if (!is_dir($currentLocalesDir)) {
|
||||
File::makeDirectory($currentLocalesDir);
|
||||
}
|
||||
|
||||
$this->compareTranslationsInDirectory($defaultLocalesDir, $currentLocalesDir);
|
||||
}
|
||||
|
||||
@@ -57,7 +61,7 @@ class Translations extends Command
|
||||
$default = include($file);
|
||||
$checked = file_exists($currentDir . '/' . $fileName) ? include $currentDir . '/' . $fileName : [];
|
||||
$this->translations = &$checked;
|
||||
|
||||
|
||||
$this->checkForMissingTranslations($default, $checked, $currentDir, $fileName);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user