[BUGFIX] Prevent resetting of Package Manager packages 52/47852/2
authorNicole Cordes <typo3@cordes.co>
Fri, 22 Apr 2016 11:47:45 +0000 (13:47 +0200)
committerBenni Mack <benni@typo3.org>
Wed, 27 Apr 2016 18:39:14 +0000 (20:39 +0200)
Due to Package Manager cleanup in https://review.typo3.org/46389/
the packageStatesConfiguration property only includes active packages.

This patch prevents resetting the packages property which should store
all available package objects to the active ones.

Resolves: #75864
Releases: master
Change-Id: I44d4e074a04cc294cacf9ec9a707b2367b57a2bb
Reviewed-on: https://review.typo3.org/47852
Reviewed-by: Helmut Hummel <helmut.hummel@typo3.org>
Tested-by: Helmut Hummel <helmut.hummel@typo3.org>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Benni Mack <benni@typo3.org>
Tested-by: Benni Mack <benni@typo3.org>
Reviewed-by: Andreas Fernandez <typo3@scripting-base.de>
typo3/sysext/core/Classes/Package/PackageManager.php

index 15d3d4d..421aae8 100644 (file)
@@ -688,13 +688,10 @@ class PackageManager implements \TYPO3\CMS\Core\SingletonInterface
         $sortedPackageKeys = $this->dependencyResolver->sortPackageStatesConfigurationByDependency($packagesWithDependencies);
 
         // Reorder the packages according to the loading order
-        $newPackages = array();
         $this->packageStatesConfiguration['packages'] = [];
         foreach ($sortedPackageKeys as $packageKey) {
-            $newPackages[$packageKey] = $this->packages[$packageKey];
             $this->registerActivePackage($this->packages[$packageKey]);
         }
-        $this->packages = $newPackages;
         return $packagesWithDependencies;
     }