From 5c965c154d1e68dd0e93eaf57fad3c3ea6b1d9c6 Mon Sep 17 00:00:00 2001 From: Vuong Minh Date: Tue, 7 May 2019 12:40:54 +0700 Subject: [PATCH] Move an autoload to runtime dir --- src/Async.php | 2 +- .../AutoloadRuntime.php} | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) rename src/{RuntimeAutoload.php => runtime/AutoloadRuntime.php} (77%) diff --git a/src/Async.php b/src/Async.php index f965c0c..f453ec5 100644 --- a/src/Async.php +++ b/src/Async.php @@ -116,7 +116,7 @@ class Async extends Component public function __construct($config = []) { $pool = $this->pool = Yii::createObject(Pool::class); - $pool->autoload(__DIR__ . '/RuntimeAutoload.php'); + $pool->autoload(__DIR__ . '/runtime/AutoloadRuntime.php'); parent::__construct($config); } diff --git a/src/RuntimeAutoload.php b/src/runtime/AutoloadRuntime.php similarity index 77% rename from src/RuntimeAutoload.php rename to src/runtime/AutoloadRuntime.php index 40d2338..3e790c3 100644 --- a/src/RuntimeAutoload.php +++ b/src/runtime/AutoloadRuntime.php @@ -13,16 +13,16 @@ { const AUTOLOAD_PATHS = [ [ + __DIR__ . '/../../../../autoload.php', __DIR__ . '/../../../autoload.php', - __DIR__ . '/../../autoload.php', - __DIR__ . '/../vendor/autoload.php', - __DIR__ . '/../../vendor/autoload.php' + __DIR__ . '/../../vendor/autoload.php', + __DIR__ . '/../../../vendor/autoload.php' ], [ + __DIR__ . '/../../../../yiisoft/yii2/Yii.php', __DIR__ . '/../../../yiisoft/yii2/Yii.php', - __DIR__ . '/../../yiisoft/yii2/Yii.php', - __DIR__ . '/../vendor/yiisoft/yii2/Yii.php', - __DIR__ . '/../../vendor/yiisoft/yii2/Yii.php' + __DIR__ . '/../../vendor/yiisoft/yii2/Yii.php', + __DIR__ . '/../../../vendor/yiisoft/yii2/Yii.php' ] ];