[FrameworkBundle] [Translation] Fixed translations not written when no translations directory in update command

This commit is contained in:
Jérémy Romey 2015-11-30 14:03:45 +01:00
parent 13fda1c7c5
commit 8c45107856

View File

@ -188,9 +188,11 @@ EOF
}
}
if ($bundleTransPath) {
$writer->writeTranslations($operation->getResult(), $input->getOption('output-format'), array('path' => $bundleTransPath, 'default_locale' => $this->getContainer()->getParameter('kernel.default_locale')));
if (!$bundleTransPath) {
$bundleTransPath = end($transPaths).'translations';
}
$writer->writeTranslations($operation->getResult(), $input->getOption('output-format'), array('path' => $bundleTransPath, 'default_locale' => $this->getContainer()->getParameter('kernel.default_locale')));
}
$output->newLine();