FEATURE: create directory for translations if not exist

This commit is contained in:
Michal Kváček
2016-07-22 00:42:45 +02:00
parent 5b54f6d45f
commit 181e1fb721
+5 -1
View File
@@ -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);
}