Passed
Push — v6 ( b3cd76...25b5d7 )
by 光春
02:42
created
src/command/Install.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@
 block discarded – undo
44 44
         $this->name = trim($input->getArgument('name'));
45 45
         if (empty($this->name)) {
46 46
             $this->output->writeln('name of online installation cannot be empty');
47
-        } else {
47
+        }else {
48 48
             $this->output->writeln("The specified module {$this->name} is not configured with installation rules");
49 49
         }
50 50
     }
Please login to merge, or discard this patch.
src/command/Version.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,6 +34,6 @@
 block discarded – undo
34 34
 
35 35
     protected function execute(Input $input, Output $output)
36 36
     {
37
-        $output->writeln('ThinkPHP ' . App::VERSION);
37
+        $output->writeln('ThinkPHP '.App::VERSION);
38 38
     }
39 39
 }
Please login to merge, or discard this patch.
src/config.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
 
20 20
 return [
21 21
     // IP数据库文件存放位置
22
-    'ip_path' => app()->getRuntimePath() . 'dtapp/ip/',
22
+    'ip_path' => app()->getRuntimePath().'dtapp/ip/',
23 23
     // 淘宝
24 24
     'taobao' => [
25 25
         // 淘宝客
Please login to merge, or discard this patch.
src/helper/Ints.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
 // | Packagist 地址 :https://packagist.org/packages/liguangchun/think-library
18 18
 // +----------------------------------------------------------------------
19 19
 
20
-declare (strict_types=1);
20
+declare(strict_types=1);
21 21
 
22 22
 namespace DtApp\ThinkLibrary\helper;
23 23
 
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
      */
36 36
     public function isEvenNumbers(int $num): bool
37 37
     {
38
-        if ($num % 2 == 0) {
38
+        if ($num%2 == 0) {
39 39
             return true;
40 40
         }
41 41
         return false;
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
      */
49 49
     public function isOddNumbers(int $num): bool
50 50
     {
51
-        if ($num % 2 == 0) {
51
+        if ($num%2 == 0) {
52 52
             return false;
53 53
         }
54 54
         return true;
Please login to merge, or discard this patch.
src/helper/Dates.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@
 block discarded – undo
17 17
 // | Packagist 地址 :https://packagist.org/packages/liguangchun/think-library
18 18
 // +----------------------------------------------------------------------
19 19
 
20
-declare (strict_types=1);
20
+declare(strict_types=1);
21 21
 
22 22
 namespace DtApp\ThinkLibrary\helper;
23 23
 
Please login to merge, or discard this patch.
src/helper/Times.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
 // | Packagist 地址 :https://packagist.org/packages/liguangchun/think-library
18 18
 // +----------------------------------------------------------------------
19 19
 
20
-declare (strict_types=1);
20
+declare(strict_types=1);
21 21
 
22 22
 namespace DtApp\ThinkLibrary\helper;
23 23
 
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
         date_default_timezone_set('Asia/Shanghai');
59 59
         $msec = 0;
60 60
         list($msec, $sec) = explode(' ', microtime());
61
-        return (float)sprintf('%.0f', (floatval($msec) + floatval($sec)) * 1000);
61
+        return (float)sprintf('%.0f', (floatval($msec)+floatval($sec))*1000);
62 62
     }
63 63
 
64 64
     /**
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
         date_default_timezone_set('Asia/Shanghai');
73 73
         $end_time = strtotime($end_time);
74 74
         $start_time = $start_time == '' ? time() : strtotime($start_time);
75
-        return $end_time - $start_time;
75
+        return $end_time-$start_time;
76 76
     }
77 77
 
78 78
     /**
@@ -111,7 +111,7 @@  discard block
 block discarded – undo
111 111
         if (empty($time)) {
112 112
             $time = time();
113 113
         }
114
-        return date($format, $time - $mun);
114
+        return date($format, $time-$mun);
115 115
     }
116 116
 
117 117
     /**
@@ -127,7 +127,7 @@  discard block
 block discarded – undo
127 127
         if (empty($time)) {
128 128
             $time = time();
129 129
         }
130
-        return date($format, $time + $mun);
130
+        return date($format, $time+$mun);
131 131
     }
132 132
 
133 133
 
@@ -141,9 +141,9 @@  discard block
 block discarded – undo
141 141
     {
142 142
         date_default_timezone_set('Asia/Shanghai');
143 143
         $date = date('H:i');
144
-        $curTime = strtotime($date);//当前时分
145
-        $assignTime1 = strtotime($start);//获得指定分钟时间戳,00:00
146
-        $assignTime2 = strtotime($end);//获得指定分钟时间戳,01:00
144
+        $curTime = strtotime($date); //当前时分
145
+        $assignTime1 = strtotime($start); //获得指定分钟时间戳,00:00
146
+        $assignTime2 = strtotime($end); //获得指定分钟时间戳,01:00
147 147
         $result = false;
148 148
         if ($curTime > $assignTime1 && $curTime < $assignTime2) {
149 149
             $result = true;
Please login to merge, or discard this patch.
src/helper/Xmls.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
 // | Packagist 地址 :https://packagist.org/packages/liguangchun/think-library
18 18
 // +----------------------------------------------------------------------
19 19
 
20
-declare (strict_types=1);
20
+declare(strict_types=1);
21 21
 
22 22
 namespace DtApp\ThinkLibrary\helper;
23 23
 
@@ -44,11 +44,11 @@  discard block
 block discarded – undo
44 44
         $xml = "<xml>";
45 45
         foreach ($values as $key => $val) {
46 46
             if (is_array($val)) {
47
-                $xml .= "<" . $key . ">" . $this->toXml($val) . "</" . $key . ">";
48
-            } else if (is_numeric($val)) {
49
-                $xml .= "<" . $key . ">" . $val . "</" . $key . ">";
50
-            } else {
51
-                $xml .= "<" . $key . "><![CDATA[" . $val . "]]></" . $key . ">";
47
+                $xml .= "<".$key.">".$this->toXml($val)."</".$key.">";
48
+            }else if (is_numeric($val)) {
49
+                $xml .= "<".$key.">".$val."</".$key.">";
50
+            }else {
51
+                $xml .= "<".$key."><![CDATA[".$val."]]></".$key.">";
52 52
             }
53 53
         }
54 54
         $xml .= "</xml>";
Please login to merge, or discard this patch.
src/facade/Randoms.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@
 block discarded – undo
17 17
 // | Packagist 地址 :https://packagist.org/packages/liguangchun/think-library
18 18
 // +----------------------------------------------------------------------
19 19
 
20
-declare (strict_types=1);
20
+declare(strict_types=1);
21 21
 
22 22
 namespace DtApp\ThinkLibrary\facade;
23 23
 
Please login to merge, or discard this patch.
src/exception/ThinkException.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -105,7 +105,7 @@
 block discarded – undo
105 105
                         'domain' => request()->domain(),
106 106
                         'url' => request()->url(),
107 107
                         'node' => config('dtapp.exception.wechat.node', ''),
108
-                        'info' => "ServerIp:" . $ip . ";CdnIp:" . $_SERVER['REMOTE_ADDR'] . ";ClientIp:" . get_ip(),
108
+                        'info' => "ServerIp:".$ip.";CdnIp:".$_SERVER['REMOTE_ADDR'].";ClientIp:".get_ip(),
109 109
                         'ip' => $ipinfo['location_all'],
110 110
                         'error' => base64_encode($msg)
111 111
                     ])
Please login to merge, or discard this patch.