Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Removing service initializer as of zendframework/zf2#3537

  • Loading branch information...
commit c62a95a7f39fca7397bb8bcb8f552547cc29e555 1 parent a3bc5ea
@Ocramius authored
View
1  library/Zend/Mvc/Service/AbstractPluginManagerFactory.php
@@ -36,7 +36,6 @@ public function createService(ServiceLocatorInterface $serviceLocator)
if (isset($configuration['di']) && $serviceLocator->has('Di')) {
$plugins->addAbstractFactory($serviceLocator->get('DiAbstractServiceFactory'));
- $plugins->addInitializer($serviceLocator->get('DiServiceInitializer'));
}
return $plugins;
View
9 library/Zend/Mvc/Service/DiServiceInitializerFactory.php
@@ -24,13 +24,6 @@ class DiServiceInitializerFactory implements FactoryInterface
*/
public function createService(ServiceLocatorInterface $serviceLocator)
{
- $initializer = new DiServiceInitializer($serviceLocator->get('Di'), $serviceLocator);
-
- if ($serviceLocator instanceof ServiceManager) {
- /* @var $serviceLocator ServiceManager */
- $serviceLocator->addInitializer($initializer);
- }
-
- return $initializer;
+ return new DiServiceInitializer($serviceLocator->get('Di'), $serviceLocator);
}
}
View
2  tests/ZendTest/Mvc/Service/DiFactoryTest.php
@@ -15,7 +15,7 @@
class DiFactoryTest extends \PHPUnit_Framework_TestCase
{
- public function testWillInitializeDiAndDiAbstractFactoryAndDiInitializer()
+ public function testWillInitializeDiAndDiAbstractFactory()
{
$serviceManager = new ServiceManager();
$serviceManager->setService('Config', array('di' => array('')));
Please sign in to comment.
Something went wrong with that request. Please try again.