Test Setup Failed
Push — master ( fc46a7...5a8c02 )
by Php Easy Api
03:40
created
src/resta/Support/TrackLogger.php 2 patches
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -23,11 +23,11 @@  discard block
 block discarded – undo
23 23
      * @param $output
24 24
      * @param $arguments
25 25
      */
26
-    public function __construct(ApplicationContracts $app,$output,$arguments)
26
+    public function __construct(ApplicationContracts $app, $output, $arguments)
27 27
     {
28 28
         parent::__construct($app);
29 29
 
30
-        if(!$this->app->runningInConsole()){
30
+        if (!$this->app->runningInConsole()) {
31 31
             exception()->runtime('Console application is missing');
32 32
         }
33 33
 
@@ -42,31 +42,31 @@  discard block
 block discarded – undo
42 42
      */
43 43
     public function handle()
44 44
     {
45
-        if(isset($this->arguments['filter'])){
45
+        if (isset($this->arguments['filter'])) {
46 46
 
47 47
             $filterResult = [];
48 48
             $filter = lcfirst($this->arguments['filter']);
49 49
 
50
-            foreach (explode('+',$filter) as $item){
51
-                $itemList = explode('=',$item);
52
-                if(isset($this->output[$itemList[0]]) && $this->output[$itemList[0]]==$itemList[1]){
50
+            foreach (explode('+', $filter) as $item) {
51
+                $itemList = explode('=', $item);
52
+                if (isset($this->output[$itemList[0]]) && $this->output[$itemList[0]]==$itemList[1]) {
53 53
                     $filterResult[] = true;
54 54
                 }
55
-                else{
55
+                else {
56 56
                     $filterResult[] = false;
57 57
                 }
58 58
             }
59 59
         }
60 60
 
61
-        if(!isset($filterResult) || (isset($filterResult) && is_array($filterResult) && !in_array(false,$filterResult))){
61
+        if (!isset($filterResult) || (isset($filterResult) && is_array($filterResult) && !in_array(false, $filterResult))) {
62 62
 
63
-            if($this->output['meta']['success'])
63
+            if ($this->output['meta']['success'])
64 64
             {
65 65
                 echo ''.$this->output['trackNumber'].' - SUCCESS:';
66 66
                 echo PHP_EOL;
67 67
                 echo 'Request Success : true';
68 68
             }
69
-            else{
69
+            else {
70 70
 
71 71
                 echo ''.$this->output['trackNumber'].' - ERROR:';
72 72
                 echo PHP_EOL;
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
 
85 85
             echo PHP_EOL;
86 86
             $requestClientIp = (isset($this->output['clientIp'])) ? $this->output['clientIp'] : null;
87
-            echo 'Client Ip: '.$requestClientIp ;
87
+            echo 'Client Ip: '.$requestClientIp;
88 88
 
89 89
             echo PHP_EOL;
90 90
             $requestEndpoint = (isset($this->output['requestUrl'])) ? $this->output['requestUrl'] : null;
Please login to merge, or discard this patch.
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -51,8 +51,7 @@  discard block
 block discarded – undo
51 51
                 $itemList = explode('=',$item);
52 52
                 if(isset($this->output[$itemList[0]]) && $this->output[$itemList[0]]==$itemList[1]){
53 53
                     $filterResult[] = true;
54
-                }
55
-                else{
54
+                } else{
56 55
                     $filterResult[] = false;
57 56
                 }
58 57
             }
@@ -65,8 +64,7 @@  discard block
 block discarded – undo
65 64
                 echo ''.$this->output['trackNumber'].' - SUCCESS:';
66 65
                 echo PHP_EOL;
67 66
                 echo 'Request Success : true';
68
-            }
69
-            else{
67
+            } else{
70 68
 
71 69
                 echo ''.$this->output['trackNumber'].' - ERROR:';
72 70
                 echo PHP_EOL;
Please login to merge, or discard this patch.