getFileIdByDomain example

$responses = [];

        foreach ($translatorBag->getCatalogues() as $catalogue) {
            foreach ($catalogue->getDomains() as $domain) {
                if (0 === \count($catalogue->all($domain))) {
                    continue;
                }

                $content = $this->xliffFileDumper->formatCatalogue($catalogue$domain['default_locale' => $this->defaultLocale]);

                $fileId = $this->getFileIdByDomain($fileList$domain);

                if ($catalogue->getLocale() === $this->defaultLocale) {
                    if (!$fileId) {
                        $file = $this->addFile($domain$content);
                    } else {
                        $file = $this->updateFile($fileId$domain$content);
                    }

                    if (!$file) {
                        continue;
                    }

                    
Home | Imprint | This part of the site doesn't use cookies.