[BUGFIX] Omit constructor injection for optional parameters 28/24128/15
authorAnja Leichsenring <aleichsenring@ab-softlab.de>
Sat, 28 Sep 2013 15:38:22 +0000 (17:38 +0200)
committerAnja Leichsenring <aleichsenring@ab-softlab.de>
Thu, 10 Oct 2013 10:58:17 +0000 (12:58 +0200)
commit4f8f50e952f0dc0bbf6256f2dedd232dd168a0ba
tree7c97b527c60f935acf6e395d074d4f4adcad055b
parent86c8f8076b22d2c8a02f1ddaee5fa798e49cf710
[BUGFIX] Omit constructor injection for optional parameters

ObjectManager tries to resolve and, in case of objects, inject all
constructor parameters, no matter what the calling function passes
to the constructor.

If the constructor value is optional, and no value or NULL is given
to the call, no constructor injection must take place for this parameter.

Change-Id: I646e6928cbadb486b1e2734efbe1ea5fbd953765
Resolves: #52349
Releases: 6.2
Reviewed-on: https://review.typo3.org/24128
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
Reviewed-by: Helmut Hummel
Tested-by: Helmut Hummel
Reviewed-by: Anja Leichsenring
Tested-by: Anja Leichsenring
typo3/sysext/extbase/Classes/Object/Container/ClassInfoFactory.php
typo3/sysext/extbase/Classes/Object/Container/Container.php
typo3/sysext/extbase/Tests/Unit/Object/Container/ContainerTest.php
typo3/sysext/extbase/Tests/Unit/Object/Container/Fixtures/ContainerConstructorInjectionTestFixtures.php [new file with mode: 0644]
typo3/sysext/extbase/Tests/Unit/Object/Container/Fixtures/NamespaceTestclasses.php [deleted file]