Skip to content

Commit 99f48c0

Browse files
fix: fix API lint
1 parent 9aa3963 commit 99f48c0

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

api/config/bootstrap.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,19 @@
44

55
use Symfony\Component\Dotenv\Dotenv;
66

7-
require dirname(__DIR__).'/vendor/autoload.php';
7+
require dirname(__DIR__) . '/vendor/autoload.php';
88

99
if (!class_exists(Dotenv::class)) {
1010
throw new LogicException('Please run "composer require symfony/dotenv" to load the ".env" files configuring the application.');
1111
}
1212

1313
// Load cached env vars if the .env.local.php file exists
1414
// Run "composer dump-env prod" to create it (requires symfony/flex >=1.2)
15-
if (is_array($env = @include dirname(__DIR__).'/.env.local.php') && (!isset($env['APP_ENV']) || ($_SERVER['APP_ENV'] ?? $_ENV['APP_ENV'] ?? $env['APP_ENV']) === $env['APP_ENV'])) {
15+
if (is_array($env = @include dirname(__DIR__) . '/.env.local.php') && (!isset($env['APP_ENV']) || ($_SERVER['APP_ENV'] ?? $_ENV['APP_ENV'] ?? $env['APP_ENV']) === $env['APP_ENV'])) {
1616
(new Dotenv())->usePutenv(false)->populate($env);
1717
} else {
1818
// load all the .env files
19-
(new Dotenv())->usePutenv(false)->loadEnv(dirname(__DIR__).'/.env');
19+
(new Dotenv())->usePutenv(false)->loadEnv(dirname(__DIR__) . '/.env');
2020
}
2121

2222
$_SERVER += $_ENV;

api/public/index.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@
44

55
use App\Kernel;
66

7-
require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
7+
require_once dirname(__DIR__) . '/vendor/autoload_runtime.php';
88

99
// Support CloudFlare Flexible SSL
1010
// https://developers.cloudflare.com/fundamentals/reference/http-request-headers/#cf-visitor
1111
if ($_SERVER['HTTP_CF_VISITOR'] ?? false) {
1212
$_SERVER['HTTP_X_FORWARDED_PROTO'] = json_decode($_SERVER['HTTP_CF_VISITOR'], true)['scheme'];
1313
}
1414

15-
return function (array $context) {
15+
return static function (array $context) {
1616
return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
1717
};

0 commit comments

Comments
 (0)