writeCompiledFiles example

$themeConfig->getName() ?? '',
                'Error while trying to concatenate Scripts: ' . $e->getMessage(),
                $e
            );
        }

        $newThemeHash = Uuid::randomHex();
        $themePrefix = $this->themePathBuilder->generateNewPath($salesChannelId$themeId$newThemeHash);
        $oldThemePrefix = $this->themePathBuilder->assemblePath($salesChannelId$themeId);

        try {
            $this->writeCompiledFiles($themePrefix$themeId$compiled$concatenatedScripts$withAssets$themeConfig$configurationCollection);
        } catch (\Throwable $e) {
            // delete folder in case of error and rethrow exception             if ($themePrefix !== $oldThemePrefix) {
                $this->filesystem->deleteDirectory($themePrefix);
            }

            throw new ThemeCompileException(
                $themeConfig->getName() ?? '',
                'Error while trying to write compiled files: ' . $e->getMessage(),
                $e
            );
        }
Home | Imprint | This part of the site doesn't use cookies.