@@ -8,7 +8,7 @@ |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: yunwuxin <[email protected]> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare(strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\filesystem\driver; |
14 | 14 |
@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: liu21st <[email protected]> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare(strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think; |
14 | 14 | |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | public function getConfig(string $name = null, $default = null) |
58 | 58 | { |
59 | 59 | if (!is_null($name)) { |
60 | - return $this->app->config->get('log.' . $name, $default); |
|
60 | + return $this->app->config->get('log.'.$name, $default); |
|
61 | 61 | } |
62 | 62 | |
63 | 63 | return $this->app->config->get('log'); |
@@ -184,7 +184,7 @@ discard block |
||
184 | 184 | */ |
185 | 185 | public function record($msg, string $type = 'info', array $context = [], bool $lazy = true) |
186 | 186 | { |
187 | - $channel = $this->getConfig('type_channel.' . $type); |
|
187 | + $channel = $this->getConfig('type_channel.'.$type); |
|
188 | 188 | |
189 | 189 | $this->channel($channel)->record($msg, $type, $context, $lazy); |
190 | 190 |
@@ -8,7 +8,7 @@ |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: liu21st <[email protected]> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare(strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\response; |
14 | 14 |
@@ -8,7 +8,7 @@ |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: liu21st <[email protected]> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare(strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\response; |
14 | 14 |
@@ -8,7 +8,7 @@ |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: liu21st <[email protected]> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare(strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\response; |
14 | 14 |
@@ -8,7 +8,7 @@ |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: liu21st <[email protected]> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare(strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\response; |
14 | 14 |
@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: liu21st <[email protected]> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare(strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\response; |
14 | 14 | |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | throw new \InvalidArgumentException(json_last_error_msg()); |
61 | 61 | } |
62 | 62 | |
63 | - $data = $handler . '(' . $data . ');'; |
|
63 | + $data = $handler.'('.$data.');'; |
|
64 | 64 | |
65 | 65 | return $data; |
66 | 66 | } catch (\Exception $e) { |
@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: liu21st <[email protected]> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare(strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\response; |
14 | 14 | |
@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | protected function output($data) |
42 | 42 | { |
43 | 43 | if (!$this->isContent && !is_file($data)) { |
44 | - throw new Exception('file not exists:' . $data); |
|
44 | + throw new Exception('file not exists:'.$data); |
|
45 | 45 | } |
46 | 46 | |
47 | 47 | ob_end_clean(); |
@@ -62,13 +62,13 @@ discard block |
||
62 | 62 | |
63 | 63 | $this->header['Pragma'] = 'public'; |
64 | 64 | $this->header['Content-Type'] = $mimeType ?: 'application/octet-stream'; |
65 | - $this->header['Cache-control'] = 'max-age=' . $this->expire; |
|
66 | - $this->header['Content-Disposition'] = ($this->force ? 'attachment; ' : '') . 'filename="' . $name . '"'; |
|
65 | + $this->header['Cache-control'] = 'max-age='.$this->expire; |
|
66 | + $this->header['Content-Disposition'] = ($this->force ? 'attachment; ' : '').'filename="'.$name.'"'; |
|
67 | 67 | $this->header['Content-Length'] = $size; |
68 | 68 | $this->header['Content-Transfer-Encoding'] = 'binary'; |
69 | - $this->header['Expires'] = gmdate("D, d M Y H:i:s", time() + $this->expire) . ' GMT'; |
|
69 | + $this->header['Expires'] = gmdate("D, d M Y H:i:s", time() + $this->expire).' GMT'; |
|
70 | 70 | |
71 | - $this->lastModified(gmdate('D, d M Y H:i:s', time()) . ' GMT'); |
|
71 | + $this->lastModified(gmdate('D, d M Y H:i:s', time()).' GMT'); |
|
72 | 72 | |
73 | 73 | return $this->isContent ? $data : file_get_contents($data); |
74 | 74 | } |
@@ -150,7 +150,7 @@ discard block |
||
150 | 150 | $this->name = $filename; |
151 | 151 | |
152 | 152 | if ($extension && false === strpos($filename, '.')) { |
153 | - $this->name .= '.' . pathinfo($this->data, PATHINFO_EXTENSION); |
|
153 | + $this->name .= '.'.pathinfo($this->data, PATHINFO_EXTENSION); |
|
154 | 154 | } |
155 | 155 | |
156 | 156 | return $this; |
@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: liu21st <[email protected]> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare(strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\response; |
14 | 14 | |
@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | if (0 !== strpos($data, '<?xml')) { |
57 | 57 | $encoding = $this->options['encoding']; |
58 | 58 | $xml = "<?xml version=\"1.0\" encoding=\"{$encoding}\"?>"; |
59 | - $data = $xml . $data; |
|
59 | + $data = $xml.$data; |
|
60 | 60 | } |
61 | 61 | return $data; |
62 | 62 | } |