@@ -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 | |
@@ -101,7 +101,7 @@ discard block |
||
101 | 101 | */ |
102 | 102 | public static function create($data = '', string $type = '', int $code = 200): Response |
103 | 103 | { |
104 | - $class = false !== strpos($type, '\\') ? $type : '\\think\\response\\' . ucfirst(strtolower($type)); |
|
104 | + $class = false !== strpos($type, '\\') ? $type : '\\think\\response\\'.ucfirst(strtolower($type)); |
|
105 | 105 | |
106 | 106 | if (class_exists($class)) { |
107 | 107 | return Container::getInstance()->invokeClass($class, [$data, $code]); |
@@ -150,7 +150,7 @@ discard block |
||
150 | 150 | http_response_code($this->code); |
151 | 151 | // 发送头部信息 |
152 | 152 | foreach ($this->header as $name => $val) { |
153 | - header($name . (!is_null($val) ? ':' . $val : '')); |
|
153 | + header($name.(!is_null($val) ? ':'.$val : '')); |
|
154 | 154 | } |
155 | 155 | } |
156 | 156 | |
@@ -343,7 +343,7 @@ discard block |
||
343 | 343 | */ |
344 | 344 | public function contentType(string $contentType, string $charset = 'utf-8') |
345 | 345 | { |
346 | - $this->header['Content-Type'] = $contentType . '; charset=' . $charset; |
|
346 | + $this->header['Content-Type'] = $contentType.'; charset='.$charset; |
|
347 | 347 | |
348 | 348 | return $this; |
349 | 349 | } |
@@ -8,7 +8,7 @@ |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: 麦当苗儿 <[email protected]> <http://zjzit.cn> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare (strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\initializer; |
14 | 14 |
@@ -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\initializer; |
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 | |
@@ -387,7 +387,7 @@ discard block |
||
387 | 387 | $this->data = $data; |
388 | 388 | } |
389 | 389 | |
390 | - $sessionId = md5(microtime(true) . uniqid()); |
|
390 | + $sessionId = md5(microtime(true).uniqid()); |
|
391 | 391 | |
392 | 392 | $this->setId($sessionId); |
393 | 393 | return $sessionId; |
@@ -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 | |
@@ -64,8 +64,8 @@ discard block |
||
64 | 64 | { |
65 | 65 | if (is_file($file)) { |
66 | 66 | $filename = $file; |
67 | - } elseif (is_file($this->path . $file . $this->ext)) { |
|
68 | - $filename = $this->path . $file . $this->ext; |
|
67 | + } elseif (is_file($this->path.$file.$this->ext)) { |
|
68 | + $filename = $this->path.$file.$this->ext; |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | if (isset($filename)) { |
@@ -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; |
14 | 14 |
@@ -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\facade; |
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\cache; |
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\session\driver; |
14 | 14 | |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | */ |
90 | 90 | public function read(string $sessID): string |
91 | 91 | { |
92 | - return (string) $this->handler->get($this->config['prefix'] . $sessID); |
|
92 | + return (string) $this->handler->get($this->config['prefix'].$sessID); |
|
93 | 93 | } |
94 | 94 | |
95 | 95 | /** |
@@ -101,7 +101,7 @@ discard block |
||
101 | 101 | */ |
102 | 102 | public function write(string $sessID, string $data): bool |
103 | 103 | { |
104 | - return $this->handler->set($this->config['prefix'] . $sessID, $data, $this->config['expire']); |
|
104 | + return $this->handler->set($this->config['prefix'].$sessID, $data, $this->config['expire']); |
|
105 | 105 | } |
106 | 106 | |
107 | 107 | /** |
@@ -112,7 +112,7 @@ discard block |
||
112 | 112 | */ |
113 | 113 | public function delete(string $sessID): bool |
114 | 114 | { |
115 | - return $this->handler->delete($this->config['prefix'] . $sessID); |
|
115 | + return $this->handler->delete($this->config['prefix'].$sessID); |
|
116 | 116 | } |
117 | 117 | |
118 | 118 | } |