/** * Import the translation files from the defined bundles. * @param ImportCommand $importCommand * @return int The total number of imported files */ private function importCustomBundlesTranslationFiles(ImportCommand $importCommand) { $imported = 0; foreach ($importCommand->getBundles() as $bundle) { $importCommand->setDefaultBundle(strtolower($bundle)); try { $imported += $this->importSingleBundleTranslationFiles($importCommand); } catch (TranslationsNotFoundException $e) { continue; } } return $imported; }