From 3b3b5561e2aa35b724d829803ef0472dd7d4c71d Mon Sep 17 00:00:00 2001 From: Qiang Xue Date: Sun, 18 Aug 2013 20:33:11 -0400 Subject: [PATCH] Fixed yii autoload precedence. --- web/index-test.php | 2 +- web/index.php | 2 +- yii | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/web/index-test.php b/web/index-test.php index 80d0953..79273ae 100644 --- a/web/index-test.php +++ b/web/index-test.php @@ -8,8 +8,8 @@ defined('YII_DEBUG') or define('YII_DEBUG', true); defined('YII_ENV') or define('YII_ENV', 'test'); -require_once(__DIR__ . '/../vendor/yiisoft/yii2/yii/Yii.php'); require_once(__DIR__ . '/../vendor/autoload.php'); +require_once(__DIR__ . '/../vendor/yiisoft/yii2/yii/Yii.php'); Yii::importNamespaces(require(__DIR__ . '/../vendor/composer/autoload_namespaces.php')); $config = require(__DIR__ . '/../config/web-test.php'); diff --git a/web/index.php b/web/index.php index e4b0cc9..51673d3 100644 --- a/web/index.php +++ b/web/index.php @@ -4,8 +4,8 @@ defined('YII_DEBUG') or define('YII_DEBUG', true); defined('YII_ENV') or define('YII_ENV', 'dev'); -require(__DIR__ . '/../vendor/yiisoft/yii2/yii/Yii.php'); require(__DIR__ . '/../vendor/autoload.php'); +require(__DIR__ . '/../vendor/yiisoft/yii2/yii/Yii.php'); Yii::importNamespaces(require(__DIR__ . '/../vendor/composer/autoload_namespaces.php')); $config = require(__DIR__ . '/../config/web.php'); diff --git a/yii b/yii index 73968c1..cd979ca 100755 --- a/yii +++ b/yii @@ -13,8 +13,8 @@ defined('YII_DEBUG') or define('YII_DEBUG', true); // fcgi doesn't have STDIN defined by default defined('STDIN') or define('STDIN', fopen('php://stdin', 'r')); -require(__DIR__ . '/vendor/yiisoft/yii2/yii/Yii.php'); require(__DIR__ . '/vendor/autoload.php'); +require(__DIR__ . '/vendor/yiisoft/yii2/yii/Yii.php'); Yii::importNamespaces(require(__DIR__ . '/vendor/composer/autoload_namespaces.php')); $config = require(__DIR__ . '/config/console.php');