Commit d1d2b3c6 authored by Helmut Hummel's avatar Helmut Hummel
Browse files

[BUGFIX] Call extension installer only with extension packages

Calling the TYPO3 extension installer with a root package
of a different type will lead to an exception to be thrown.

Move the install path check after the type check, to be sure
to call the installer only with extension types.

Resolves: #96028
Related: #96021
Releases: master, 11.5
Change-Id: Icdebc1a541a0b43461559e8f7a4a999fb1b327f3

Tested-by: Simon Gilli's avatarSimon Gilli <>
Tested-by: Helmut Hummel's avatarHelmut Hummel <>
Tested-by: Georg Ringer's avatarGeorg Ringer <>
Reviewed-by: Simon Gilli's avatarSimon Gilli <>
Reviewed-by: Helmut Hummel's avatarHelmut Hummel <>
Reviewed-by: Georg Ringer's avatarGeorg Ringer <>
Reviewed-by: Benni Mack's avatarBenni Mack <>
parent 1342dd32
......@@ -225,13 +225,15 @@ class PackageArtifactBuilder extends PackageManager implements InstallerScript
$baseDir = $this->config->get('base-dir');
$composer = $this->event->getComposer();
$typo3ExtensionInstallPath = $composer->getInstallationManager()->getInstaller('typo3-cms-extension')->getInstallPath($rootPackage);
if ($rootPackage->getType() !== 'typo3-cms-extension'
|| !file_exists($baseDir . '/Resources/Public/')
|| strpos($typo3ExtensionInstallPath, self::LEGACY_EXTENSION_INSTALL_PATH) === false
) {
return [$rootPackage, $baseDir, $extensionKey];
$typo3ExtensionInstallPath = $composer->getInstallationManager()->getInstaller('typo3-cms-extension')->getInstallPath($rootPackage);
if (strpos($typo3ExtensionInstallPath, self::LEGACY_EXTENSION_INSTALL_PATH) === false) {
return [$rootPackage, $baseDir, $extensionKey];
$filesystem = new Filesystem();
if (!file_exists($typo3ExtensionInstallPath) && !$filesystem->isSymlinkedDirectory($typo3ExtensionInstallPath)) {
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment