From 31b213be7b7359cc2ada96863c699ad49c743316 Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Mon, 2 Oct 2017 22:14:35 +1300 Subject: [PATCH] Allow autoloading from vendor path --- src/includes/autoload.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/includes/autoload.php b/src/includes/autoload.php index 4a1af9117..67baec014 100644 --- a/src/includes/autoload.php +++ b/src/includes/autoload.php @@ -3,8 +3,13 @@ // Init composer autoload call_user_func(function () { $candidates = [ + // module in vendor + __DIR__ . '/../../../../autoload.php', + // module in webroot __DIR__ . '/../../vendor/autoload.php', + // module in webroot __DIR__ . '/../../../vendor/autoload.php', + // module is webroot (usually during CI installs) getcwd() . '/vendor/autoload.php', ]; foreach ($candidates as $candidate) {