Skip to content
This repository has been archived by the owner on Oct 8, 2024. It is now read-only.

Commit

Permalink
Merge branch 'next-20852/add-disable-extensions-support' into 'trunk'
Browse files Browse the repository at this point in the history
NEXT-20852 - Add support for DISABLE_EXTENSIONS env var

See merge request shopware/6/product/development!329
  • Loading branch information
shyim committed Apr 4, 2022
2 parents 7e2c1ce + ea14b3e commit a6e595c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions bin/console
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,10 @@ if ($debug) {
}

$kernel = new HttpKernel($env, $debug, $classLoader);

if ($_SERVER['COMPOSER_PLUGIN_LOADER'] ?? $_SERVER['DISABLE_EXTENSIONS'] ?? false) {
$kernel->setPluginLoader(new \Shopware\Core\Framework\Plugin\KernelPluginLoader\ComposerPluginLoader($classLoader));
}

$application = new Application($kernel->getKernel());
$application->run($input);
5 changes: 5 additions & 0 deletions public/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,11 @@
$request = Request::createFromGlobals();

$kernel = new HttpKernel($appEnv, $debug, $classLoader);

if ($_SERVER['COMPOSER_PLUGIN_LOADER'] ?? $_SERVER['DISABLE_EXTENSIONS'] ?? false) {
$kernel->setPluginLoader(new \Shopware\Core\Framework\Plugin\KernelPluginLoader\ComposerPluginLoader($classLoader));
}

$result = $kernel->handle($request);

$result->getResponse()->send();
Expand Down

0 comments on commit a6e595c

Please sign in to comment.