From 5465bf5d6b3159aaf06e7e5594881dd817bcee5f Mon Sep 17 00:00:00 2001 From: cakyus Date: Wed, 10 Feb 2016 00:08:44 +0700 Subject: [PATCH] * load vendor/autoload.php --- public/index.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/public/index.php b/public/index.php index d510a13..4cd55e2 100644 --- a/public/index.php +++ b/public/index.php @@ -14,9 +14,13 @@ // Include the autoloader class handler require $vendorDir.'panada' . DIRECTORY_SEPARATOR . 'loader' . DIRECTORY_SEPARATOR . 'Auto.php'; -new Panada\Loader\Auto($vendorDir); +if (is_file($vendorDir . DIRECTORY_SEPARATOR . 'autoload.php')) { + include_once($vendorDir . DIRECTORY_SEPARATOR . 'autoload.php'); +} else { + new Panada\Loader\Auto($vendorDir); +} Panada\Resource\Gear::send( Panada\Http\Uri::getInstance(), $appDir -); \ No newline at end of file +);