From 3b98fa73967225ee98f934d3bef676460b6751e0 Mon Sep 17 00:00:00 2001 From: Allon Moritz Date: Mon, 20 Aug 2018 13:21:49 +0200 Subject: [PATCH] Move com_workflow to services (#21760) --- .../components/com_workflow/dispatcher.php | 29 ----------- .../com_workflow/services/provider.php | 52 +++++++++++++++++++ 2 files changed, 52 insertions(+), 29 deletions(-) delete mode 100644 administrator/components/com_workflow/dispatcher.php create mode 100644 administrator/components/com_workflow/services/provider.php diff --git a/administrator/components/com_workflow/dispatcher.php b/administrator/components/com_workflow/dispatcher.php deleted file mode 100644 index 9086fbf177120..0000000000000 --- a/administrator/components/com_workflow/dispatcher.php +++ /dev/null @@ -1,29 +0,0 @@ -registerServiceProvider(new MVCFactoryFactory('\\Joomla\\Component\\Workflow')); + $container->registerServiceProvider(new DispatcherFactory('\\Joomla\\Component\\Workflow')); + $container->set( + ComponentInterface::class, + function (Container $container) + { + $component = new MVCComponent($container->get(DispatcherFactoryInterface::class)); + $component->setMvcFactoryFactory($container->get(MVCFactoryFactoryInterface::class)); + + return $component; + } + ); + } +};