@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: zhangyajun <[email protected]> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare (strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\model; |
14 | 14 | |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | */ |
41 | 41 | public function hidden(array $hidden, bool $override = false) |
42 | 42 | { |
43 | - $this->each(function (Model $model) use ($hidden, $override) { |
|
43 | + $this->each(function(Model $model) use ($hidden, $override) { |
|
44 | 44 | $model->hidden($hidden, $override); |
45 | 45 | }); |
46 | 46 | |
@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | */ |
57 | 57 | public function visible(array $visible, bool $override = false) |
58 | 58 | { |
59 | - $this->each(function (Model $model) use ($visible, $override) { |
|
59 | + $this->each(function(Model $model) use ($visible, $override) { |
|
60 | 60 | $model->visible($visible, $override); |
61 | 61 | }); |
62 | 62 | |
@@ -72,7 +72,7 @@ discard block |
||
72 | 72 | */ |
73 | 73 | public function append(array $append, bool $override = false) |
74 | 74 | { |
75 | - $this->each(function (Model $model) use ($append, $override) { |
|
75 | + $this->each(function(Model $model) use ($append, $override) { |
|
76 | 76 | $model && $model->append($append, $override); |
77 | 77 | }); |
78 | 78 | |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | */ |
89 | 89 | public function withAttr($name, $callback = null) |
90 | 90 | { |
91 | - $this->each(function ($model) use ($name, $callback) { |
|
91 | + $this->each(function($model) use ($name, $callback) { |
|
92 | 92 | /** @var Model $model */ |
93 | 93 | $model && $model->withAttribute($name, $callback); |
94 | 94 | }); |
@@ -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\model; |
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\model; |
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; |
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\session\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\session\driver; |
14 | 14 | |
@@ -59,8 +59,7 @@ discard block |
||
59 | 59 | foreach ($hosts as $i => $host) { |
60 | 60 | $port = $ports[$i] ?? $ports[0]; |
61 | 61 | $this->config['timeout'] > 0 ? |
62 | - $this->handler->addServer($host, $port, $this->config['persistent'], 1, $this->config['timeout']) : |
|
63 | - $this->handler->addServer($host, $port, $this->config['persistent'], 1); |
|
62 | + $this->handler->addServer($host, $port, $this->config['persistent'], 1, $this->config['timeout']) : $this->handler->addServer($host, $port, $this->config['persistent'], 1); |
|
64 | 63 | } |
65 | 64 | |
66 | 65 | return true; |
@@ -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\session\driver; |
14 | 14 |
@@ -8,7 +8,7 @@ discard block |
||
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\console; |
14 | 14 | |
@@ -256,7 +256,7 @@ discard block |
||
256 | 256 | $content .= $this->renderSeparator('middle'); |
257 | 257 | } elseif (is_scalar($row)) { |
258 | 258 | $content .= $this->renderSeparator('cross-top'); |
259 | - $array = str_pad($row, 3 * (count($this->colWidth) - 1) + array_reduce($this->colWidth, function ($a, $b) { |
|
259 | + $array = str_pad($row, 3 * (count($this->colWidth) - 1) + array_reduce($this->colWidth, function($a, $b) { |
|
260 | 260 | return $a + $b; |
261 | 261 | })); |
262 | 262 |
@@ -114,7 +114,7 @@ |
||
114 | 114 | $sort = $this->sortBy[$sort]; |
115 | 115 | } |
116 | 116 | |
117 | - uasort($rows, function ($a, $b) use ($sort) { |
|
117 | + uasort($rows, function($a, $b) use ($sort) { |
|
118 | 118 | $itemA = $a[$sort] ?? null; |
119 | 119 | $itemB = $b[$sort] ?? null; |
120 | 120 |