public function comfirmImportation($locale = null) { // Persisting locale [all], means to persist all locale separatly $locales = array($locale); if ($locale == 'all') { $locales = array_keys($this->getTranslationsFromSession()); } // Import foreach ($locales as $locale) { $this->doImport($locale); } // Save and clear cache $stat = $this->repository->persist(); $this->translator->clearCache(); return $stat; }