@@ -9,9 +9,9 @@ |
||
9 | 9 | public static function get(string $key, $default = null): callable |
10 | 10 | { |
11 | 11 | if (count(func_get_args()) === 2) { |
12 | - return static fn () => $_ENV[$key] ?? $default; |
|
12 | + return static fn() => $_ENV[$key] ?? $default; |
|
13 | 13 | } |
14 | 14 | |
15 | - return static fn () => $_ENV[$key]; |
|
15 | + return static fn() => $_ENV[$key]; |
|
16 | 16 | } |
17 | 17 | } |
@@ -247,6 +247,6 @@ |
||
247 | 247 | */ |
248 | 248 | public static function require(string $config): callable |
249 | 249 | { |
250 | - return static fn () => require $config; |
|
250 | + return static fn() => require $config; |
|
251 | 251 | } |
252 | 252 | } |
@@ -39,7 +39,6 @@ |
||
39 | 39 | |
40 | 40 | /** |
41 | 41 | * Returns ordered list of packages: |
42 | - |
|
43 | 42 | * - Packages listed earlier in the composer.json will get earlier in the list. |
44 | 43 | * - Children are listed before parents. |
45 | 44 | * |
@@ -13,7 +13,7 @@ |
||
13 | 13 | { |
14 | 14 | protected function writeFile(string $path, array $data): void |
15 | 15 | { |
16 | - if($data) { |
|
16 | + if ($data) { |
|
17 | 17 | $envs = '[]'; //Helper::exportVar($data); |
18 | 18 | } else { |
19 | 19 | $envs = '[]'; |
@@ -28,7 +28,7 @@ |
||
28 | 28 | public static function pushValues(array $data, array $values, string $prefix = null) |
29 | 29 | { |
30 | 30 | foreach ($data as $key => &$value) { |
31 | - $subkey = $prefix===null ? $key : "${prefix}_$key"; |
|
31 | + $subkey = $prefix === null ? $key : "${prefix}_$key"; |
|
32 | 32 | |
33 | 33 | $envkey = self::getEnvKey($subkey); |
34 | 34 | if (isset($values[$envkey])) { |
@@ -119,7 +119,7 @@ |
||
119 | 119 | $limit = 10; |
120 | 120 | while (preg_match('~\'__(\w+)__\'~', $output)) { |
121 | 121 | // TODO will be fixed soon |
122 | - if (--$limit<1) { |
|
122 | + if (--$limit < 1) { |
|
123 | 123 | throw new \Exception('too much'); |
124 | 124 | } |
125 | 125 | $output = strtr($output, static::$tokens); |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | { |
37 | 37 | $params = $this->builder->getVars()['params'] ?? []; |
38 | 38 | |
39 | - $result = static function (array $params) { |
|
39 | + $result = static function(array $params) { |
|
40 | 40 | return require func_get_arg(1); |
41 | 41 | }; |
42 | 42 | |
@@ -54,7 +54,7 @@ discard block |
||
54 | 54 | protected function extractUses($ast) |
55 | 55 | { |
56 | 56 | /** @var Stmt $node */ |
57 | - foreach ($ast as $node){ |
|
57 | + foreach ($ast as $node) { |
|
58 | 58 | if (isset($node->type) && $node->type == Use_::TYPE_NORMAL and !empty($node->uses)) { |
59 | 59 | foreach ($node->uses as $use) { |
60 | 60 | $className = end($use->name->parts); |