From 497b8f89333bca577dc2ccbdc931c461d8b923e5 Mon Sep 17 00:00:00 2001 From: Maddy Chellathurai <mchellathura@magento.com> Date: Fri, 27 May 2016 08:53:30 -0500 Subject: [PATCH] MAGETWO-53474: [Github] Caches Aren't Enabled by Default on RC1 with Composer when Upgrading via CLI - CR comments --- .../Setup/Console/Command/UpgradeCommand.php | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/setup/src/Magento/Setup/Console/Command/UpgradeCommand.php b/setup/src/Magento/Setup/Console/Command/UpgradeCommand.php index 07453181a88..34b74e4493b 100644 --- a/setup/src/Magento/Setup/Console/Command/UpgradeCommand.php +++ b/setup/src/Magento/Setup/Console/Command/UpgradeCommand.php @@ -98,7 +98,18 @@ class UpgradeCommand extends AbstractSetupCommand $output->writeln('<info>Please re-run Magento compile command</info>'); } - //TODO: to be removed in scope of MAGETWO-53476 + return $this->doSomething($objectManager); + } + + /** + * Enables cache if cachestates exists + * TODO: to be removed in scope of MAGETWO-53476 + * + * @param \Magento\Framework\ObjectManagerInterface $objectManager + * @return int + */ + private function doSomething($objectManager) + { $writeFactory = $objectManager->get('Magento\Framework\Filesystem\Directory\WriteFactory'); $write = $writeFactory->create(BP); /** @var \Magento\Framework\App\Filesystem\DirectoryList $dirList */ -- GitLab