@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | // +---------------------------------------------------------------------- |
9 | 9 | // | Author: luofei614 <weibo.com/luofei614> |
10 | 10 | // +---------------------------------------------------------------------- |
11 | -declare (strict_types = 1); |
|
11 | +declare(strict_types=1); |
|
12 | 12 | |
13 | 13 | namespace think\log\driver; |
14 | 14 | |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | if ($this->app->exists('request')) { |
90 | 90 | $current_uri = $this->app->request->url(true); |
91 | 91 | } else { |
92 | - $current_uri = 'cmd:' . implode(' ', $_SERVER['argv'] ?? []); |
|
92 | + $current_uri = 'cmd:'.implode(' ', $_SERVER['argv'] ?? []); |
|
93 | 93 | } |
94 | 94 | |
95 | 95 | // 基本信息 |
@@ -105,7 +105,7 @@ discard block |
||
105 | 105 | foreach ($log as $type => $val) { |
106 | 106 | $trace[] = [ |
107 | 107 | 'type' => ($expand_level[$type] ?? false) ? 'group' : 'groupCollapsed', |
108 | - 'msg' => '[ ' . $type . ' ]', |
|
108 | + 'msg' => '[ '.$type.' ]', |
|
109 | 109 | 'css' => $this->css[$type] ?? '', |
110 | 110 | ]; |
111 | 111 | |
@@ -191,7 +191,7 @@ discard block |
||
191 | 191 | ]; |
192 | 192 | |
193 | 193 | $msg = json_encode($logs, JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES | JSON_PARTIAL_OUTPUT_ON_ERROR); |
194 | - $address = '/' . $client_id; //将client_id作为地址, server端通过地址判断将日志发布给谁 |
|
194 | + $address = '/'.$client_id; //将client_id作为地址, server端通过地址判断将日志发布给谁 |
|
195 | 195 | |
196 | 196 | $this->send($this->config['host'], $msg, $address); |
197 | 197 | } |
@@ -262,7 +262,7 @@ discard block |
||
262 | 262 | */ |
263 | 263 | protected function send($host, $message = '', $address = '/') |
264 | 264 | { |
265 | - $url = 'http://' . $host . ':' . $this->port . $address; |
|
265 | + $url = 'http://'.$host.':'.$this->port.$address; |
|
266 | 266 | $ch = curl_init(); |
267 | 267 | |
268 | 268 | curl_setopt($ch, CURLOPT_URL, $url); |