Skip to content
Permalink
Browse files

Fix: Do not load cakephp-plugins from outside of ROOT

Running tests on a vendor installed cakephp will cause plugins from its
app to be loaded.
  • Loading branch information...
rchavik committed Sep 14, 2017
1 parent 8262b4d commit 1597e6f47c65be477a9ed944c28a3bb58c7b1ae8
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/Core/Plugin.php
@@ -189,7 +189,7 @@ protected static function _loadConfig()
$vendorFile = dirname(dirname(__DIR__)) . DIRECTORY_SEPARATOR . 'cakephp-plugins.php';
if (!file_exists($vendorFile)) {
$vendorFile = dirname(dirname(dirname(dirname(__DIR__)))) . DIRECTORY_SEPARATOR . 'cakephp-plugins.php';
if (!file_exists($vendorFile)) {
if (strpos(ROOT, $vendorFile) === false || !file_exists($vendorFile)) {
Configure::write(['plugins' => []]);
return;

0 comments on commit 1597e6f

Please sign in to comment.
You can’t perform that action at this time.