clean up dirname() (#4307)

This commit is contained in:
Demin Yin 2021-12-01 17:29:46 -08:00 committed by GitHub
parent 90214aa6ae
commit ca4bb3a648
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 5 additions and 5 deletions

View File

@ -9,4 +9,4 @@ declare(strict_types=1);
* @contact group@hyperf.io
* @license https://github.com/hyperf/hyperf/blob/master/LICENSE
*/
require_once dirname(dirname(__FILE__)) . '/vendor/autoload.php';
require_once dirname(__DIR__) . '/vendor/autoload.php';

View File

@ -9,4 +9,4 @@ declare(strict_types=1);
* @contact group@hyperf.io
* @license https://github.com/hyperf/hyperf/blob/master/LICENSE
*/
require_once dirname(dirname(__FILE__)) . '/vendor/autoload.php';
require_once dirname(__DIR__) . '/vendor/autoload.php';

View File

@ -9,4 +9,4 @@ declare(strict_types=1);
* @contact group@hyperf.io
* @license https://github.com/hyperf/hyperf/blob/master/LICENSE
*/
require_once dirname(dirname(__FILE__)) . '/vendor/autoload.php';
require_once dirname(__DIR__) . '/vendor/autoload.php';

View File

@ -16,7 +16,7 @@ error_reporting(E_ALL);
date_default_timezone_set('Asia/Shanghai');
$basePath = getcwd();
$dir = dirname(dirname(dirname(__DIR__)));
$dir = dirname(__DIR__, 3);
if (file_exists($dir . '/vendor/autoload.php')) {
$basePath = $dir;

View File

@ -11,7 +11,7 @@ declare(strict_types=1);
*/
putenv('SCAN_CACHEABLE=(true)');
$dir = dirname(dirname(__DIR__));
$dir = dirname(__DIR__, 2);
$cwd = getcwd();
switch (true) {