Test Setup Failed
Push — master ( 1a8e60...3b3ded )
by Php Easy Api
02:41
created
src/resta/Console/ConsoleArguments.php 2 patches
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
     public function getArguments()
17 17
     {
18 18
         //if there is no arguments constant
19
-        if(!defined('arguments'))  define ('arguments',['api']);
19
+        if (!defined('arguments'))  define('arguments', ['api']);
20 20
 
21 21
         //get psr standard console arguments
22 22
         return core()->consoleArguments = Utils::upperCase(arguments);
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
      */
50 50
     public function getConsoleClassRealArguments()
51 51
     {
52
-        return array_slice($this->getArguments(),2);
52
+        return array_slice($this->getArguments(), 2);
53 53
     }
54 54
 
55 55
     /**
@@ -65,19 +65,19 @@  discard block
 block discarded – undo
65 65
         $listKey = [];
66 66
         $listKey['project'] = null;
67 67
 
68
-        if(property_exists($this,'consoleClassNamespace')){
68
+        if (property_exists($this, 'consoleClassNamespace')) {
69 69
             $listKey['class'] = strtolower(class_basename($this->consoleClassNamespace));
70 70
             $listKey['classMethod'] = strtolower($this->getConsoleClassMethod());
71 71
         }
72 72
 
73
-        foreach($getConsoleClassRealArguments as $key=>$value){
73
+        foreach ($getConsoleClassRealArguments as $key=>$value) {
74 74
 
75
-            if($key=="0"){
75
+            if ($key=="0") {
76 76
                 $listKey['project'] = $value;
77 77
             }
78
-            else{
78
+            else {
79 79
 
80
-                $colonExplode = explode(":",$value);
80
+                $colonExplode = explode(":", $value);
81 81
                 $listKey[strtolower($colonExplode[0])] = ucfirst($colonExplode[1]);
82 82
             }
83 83
         }
@@ -109,14 +109,14 @@  discard block
 block discarded – undo
109 109
 
110 110
         $this->getConsoleArgumentsWithKey();
111 111
 
112
-        if(isset($arguments[2])){
112
+        if (isset($arguments[2])) {
113 113
             $app = $arguments[2];
114 114
         }
115 115
 
116
-        if(!defined('group')){
117
-            define('group',StaticPathList::$projectPrefixGroup);
116
+        if (!defined('group')) {
117
+            define('group', StaticPathList::$projectPrefixGroup);
118 118
         }
119 119
 
120
-        if(!defined('app') and isset($arguments[2])) define('app',isset($app) ? $app : null);
120
+        if (!defined('app') and isset($arguments[2])) define('app', isset($app) ? $app : null);
121 121
     }
122 122
 }
123 123
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +7 added lines, -4 removed lines patch added patch discarded remove patch
@@ -16,7 +16,9 @@  discard block
 block discarded – undo
16 16
     public function getArguments()
17 17
     {
18 18
         //if there is no arguments constant
19
-        if(!defined('arguments'))  define ('arguments',['api']);
19
+        if(!defined('arguments')) {
20
+            define ('arguments',['api']);
21
+        }
20 22
 
21 23
         //get psr standard console arguments
22 24
         return core()->consoleArguments = Utils::upperCase(arguments);
@@ -74,8 +76,7 @@  discard block
 block discarded – undo
74 76
 
75 77
             if($key=="0"){
76 78
                 $listKey['project'] = $value;
77
-            }
78
-            else{
79
+            } else{
79 80
 
80 81
                 $colonExplode = explode(":",$value);
81 82
                 $listKey[strtolower($colonExplode[0])] = ucfirst($colonExplode[1]);
@@ -117,6 +118,8 @@  discard block
 block discarded – undo
117 118
             define('group',StaticPathList::$projectPrefixGroup);
118 119
         }
119 120
 
120
-        if(!defined('app') and isset($arguments[2])) define('app',isset($app) ? $app : null);
121
+        if(!defined('app') and isset($arguments[2])) {
122
+            define('app',isset($app) ? $app : null);
123
+        }
121 124
     }
122 125
 }
123 126
\ No newline at end of file
Please login to merge, or discard this patch.