Completed
Push — master ( 30b51c...942354 )
by Chubarov
24:54 queued 21:03
created
src/Handlers/XmlConverter.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -9,12 +9,12 @@  discard block
 block discarded – undo
9 9
     private function xmlToArrayRecursive($xml) {
10 10
         $xml = (array) $xml;
11 11
 
12
-        if(empty($xml)) {
12
+        if (empty($xml)) {
13 13
             return null;
14 14
         }
15 15
 
16 16
         foreach ($xml as $key => $val) {
17
-            if (is_array($val)){
17
+            if (is_array($val)) {
18 18
                 $xml[$key] = $this->xmlToArray($val);
19 19
             } else {
20 20
                 if ($val instanceof SimpleXMLElement) {
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
     private function xmlToArray($xml) {
33 33
         $xml = (array) $xml;
34 34
 
35
-        if(empty($xml)) {
35
+        if (empty($xml)) {
36 36
             return null;
37 37
         }
38 38
 
Please login to merge, or discard this patch.
src/KernelBpm.php 3 patches
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -29,8 +29,8 @@  discard block
 block discarded – undo
29 29
     ];
30 30
 
31 31
     protected $handlers = [
32
-      'xml'  => XmlHandler::class,
33
-      'json' => JsonHandler::class,
32
+        'xml'  => XmlHandler::class,
33
+        'json' => JsonHandler::class,
34 34
     ];
35 35
 
36 36
     protected $collection;
@@ -147,10 +147,10 @@  discard block
 block discarded – undo
147 147
     public function action($action, callable $callback)
148 148
     {
149 149
 
150
-         extract($this->splitAction($action));
150
+            extract($this->splitAction($action));
151 151
 
152
-         $action  = $this->setAction($action);
153
-         $this->setHandler($handler);
152
+            $action  = $this->setAction($action);
153
+            $this->setHandler($handler);
154 154
 
155 155
         $action->injectionKernel($this);
156 156
         call_user_func($callback, $action);
@@ -180,7 +180,7 @@  discard block
 block discarded – undo
180 180
         try {
181 181
             Assertion::regex($collection, '/[A-z]+Collection$/');
182 182
         } catch(AssertionFailedException $e) {
183
-           throw new \Exception("Expected word 'Collection' in parameter method setCollection received : " .  $e->getValue());
183
+            throw new \Exception("Expected word 'Collection' in parameter method setCollection received : " .  $e->getValue());
184 184
         }
185 185
 
186 186
         return $this->collection = $collection;
Please login to merge, or discard this patch.
Doc Comments   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -113,7 +113,7 @@  discard block
 block discarded – undo
113 113
     }
114 114
 
115 115
     /**
116
-     * @param       $key
116
+     * @param       string $key
117 117
      * @param array $array
118 118
      * @return void
119 119
      */
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
     }
125 125
 
126 126
     /**
127
-     * @return Handler
127
+     * @return \Illuminate\Container\Container
128 128
      */
129 129
     public function getHandler()
130 130
     {
@@ -134,7 +134,7 @@  discard block
 block discarded – undo
134 134
     /**
135 135
      * Set the response handler
136 136
      * @param string $typeHandler default xml
137
-     * @return Action
137
+     * @return \Illuminate\Container\Container
138 138
      */
139 139
     public function setHandler($typeHandler = 'xml')
140 140
     {
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
     }
153 153
 
154 154
     /**
155
-     * @param $typeAction string
155
+     * @param string $typeAction string
156 156
      * @return Action
157 157
      */
158 158
     public function setAction($typeAction)
@@ -198,7 +198,7 @@  discard block
 block discarded – undo
198 198
     /**
199 199
      * Set collection for correct query
200 200
      * @param string $collection
201
-     * @return mixed
201
+     * @return string
202 202
      * @throws \Exception
203 203
      */
204 204
     public function setCollection($collection)
@@ -228,7 +228,7 @@  discard block
 block discarded – undo
228 228
         return app()->make(ClientInterface::class);
229 229
     }
230 230
     /**
231
-     * @param $action
231
+     * @param string $action
232 232
      * @return array
233 233
      */
234 234
     private function splitAction($action)
Please login to merge, or discard this patch.
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -109,7 +109,7 @@  discard block
 block discarded – undo
109 109
      */
110 110
     public function loadConfiguration(SourceConfiguration $configuration)
111 111
     {
112
-        config()->set(  $this->prefixConfiguration = $configuration->getName(), $configuration->get());
112
+        config()->set($this->prefixConfiguration = $configuration->getName(), $configuration->get());
113 113
     }
114 114
 
115 115
     /**
@@ -159,7 +159,7 @@  discard block
 block discarded – undo
159 159
     {
160 160
         Assertion::keyIsset($this->action, $typeAction);
161 161
 
162
-        $this->currentAction  =  app()->make( $this->action[$typeAction] );
162
+        $this->currentAction = app()->make($this->action[$typeAction]);
163 163
 
164 164
         return $this->currentAction;
165 165
     }
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
 
176 176
          extract($this->splitAction($action));
177 177
 
178
-         $action  = $this->setAction($action);
178
+         $action = $this->setAction($action);
179 179
          $this->setHandler($handler);
180 180
 
181 181
         $action->injectionKernel($this);
@@ -205,8 +205,8 @@  discard block
 block discarded – undo
205 205
     {
206 206
         try {
207 207
             Assertion::regex($collection, '/[A-z]+Collection$/');
208
-        } catch(AssertionFailedException $e) {
209
-           throw new \Exception("Expected word 'Collection' in parameter method setCollection received : " .  $e->getValue());
208
+        } catch (AssertionFailedException $e) {
209
+           throw new \Exception("Expected word 'Collection' in parameter method setCollection received : " . $e->getValue());
210 210
         }
211 211
 
212 212
         return $this->collection = $collection;
@@ -237,8 +237,8 @@  discard block
 block discarded – undo
237 237
 
238 238
         // verification values
239 239
         Assertion::between(count($split), 2, 2);
240
-        Assertion::keyExists( $this->action, $split[0]);
241
-        Assertion::keyExists( $this->handlers, $split[1]);
240
+        Assertion::keyExists($this->action, $split[0]);
241
+        Assertion::keyExists($this->handlers, $split[1]);
242 242
 
243 243
         return ['action' => $split[0], 'handler' => $split[1]];
244 244
     }
Please login to merge, or discard this patch.
src/ServiceProviders/ConfigurationServiceProvider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@
 block discarded – undo
9 9
 {
10 10
     public function register()
11 11
     {
12
-        if ( app()->resolved('config') === false )
12
+        if (app()->resolved('config') === false)
13 13
         {
14 14
             app()->instance('config', new Repository());
15 15
         }
Please login to merge, or discard this patch.
src/ServiceProviders/ActionsServiceProviders.php 2 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -13,9 +13,9 @@
 block discarded – undo
13 13
 
14 14
     public function register()
15 15
     {
16
-       app()->bind(Read::class,   Read::class);
17
-       app()->bind(Create::class, Create::class);
18
-       app()->bind(Update::class, Update::class);
19
-       app()->bind(Delete::class, Delete::class);
16
+        app()->bind(Read::class,   Read::class);
17
+        app()->bind(Create::class, Create::class);
18
+        app()->bind(Update::class, Update::class);
19
+        app()->bind(Delete::class, Delete::class);
20 20
     }
21 21
 }
22 22
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
 
14 14
     public function register()
15 15
     {
16
-       app()->bind(Read::class,   Read::class);
16
+       app()->bind(Read::class, Read::class);
17 17
        app()->bind(Create::class, Create::class);
18 18
        app()->bind(Update::class, Update::class);
19 19
        app()->bind(Delete::class, Delete::class);
Please login to merge, or discard this patch.
src/SourcesConfigurations/File.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
      */
18 18
     public function get()
19 19
     {
20
-        $configuration =  require $this->pathToFile;
20
+        $configuration = require $this->pathToFile;
21 21
         return $configuration;
22 22
     }
23 23
 
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
         if (file_exists($path))
31 31
         {
32 32
             $this->pathToFile = $path;
33
-        } else{
33
+        } else {
34 34
             Assertion::file($path, 'Local file name is not exist.');
35 35
         }
36 36
         return true;
Please login to merge, or discard this patch.
example.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@
 block discarded – undo
55 55
 //dd($test);
56 56
 
57 57
 // 8.  Example delete
58
-$test = $test->action('delete:xml', function ($creator){
58
+$test = $test->action('delete:xml', function($creator) {
59 59
     $creator->guid('');
60 60
 })->get();
61 61
 dd($test);
62 62
\ No newline at end of file
Please login to merge, or discard this patch.
src/Assistants/ConstructorUrl.php 3 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
 
13 13
     /**
14 14
      * Concatenation Url In Curl
15
-     * @param $newParameters string
15
+     * @param string $newParameters string
16 16
      * @return $this
17 17
      */
18 18
     protected function concatenationUrlCurl($newParameters)
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,8 +23,7 @@
 block discarded – undo
23 23
             $this->url .= $newParameters;
24 24
         } elseif ($this->url == '/') {
25 25
             $this->url .= $newParameters;
26
-        }
27
-        else {
26
+        } else {
28 27
             $this->url .= '&'.$newParameters;
29 28
         }
30 29
         return $this;
Please login to merge, or discard this 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
      */
18 18
     protected function concatenationUrlCurl($newParameters)
19 19
     {
20
-        if ($this->url  == '?') {
20
+        if ($this->url == '?') {
21 21
             $this->url .= $newParameters;
22 22
         } elseif ($this->url == '') {
23 23
             $this->url .= $newParameters;
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
             $this->url .= $newParameters;
26 26
         }
27 27
         else {
28
-            $this->url .= '&'.$newParameters;
28
+            $this->url .= '&' . $newParameters;
29 29
         }
30 30
         return $this;
31 31
     }
@@ -40,10 +40,10 @@  discard block
 block discarded – undo
40 40
         $this->checkGuId($guid);
41 41
         $this->url      = '';
42 42
         $ParameterQuery = '(guid';
43
-        $ParameterQuery.= "'";
44
-        $ParameterQuery.= $guid;
45
-        $ParameterQuery.= "'";
46
-        $ParameterQuery.=')';
43
+        $ParameterQuery .= "'";
44
+        $ParameterQuery .= $guid;
45
+        $ParameterQuery .= "'";
46
+        $ParameterQuery .= ')';
47 47
 
48 48
         return $this->concatenationUrlCurl($ParameterQuery);
49 49
     }
Please login to merge, or discard this patch.
src/Actions/Delete.php 3 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@
 block discarded – undo
43 43
     }
44 44
 
45 45
     /**
46
-     * @return \agoalofalife\bpm\Contracts\Handler
46
+     * @return \Illuminate\Container\Container
47 47
      */
48 48
     public function processData()
49 49
     {
Please login to merge, or discard this patch.
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -68,7 +68,7 @@
 block discarded – undo
68 68
 
69 69
 
70 70
         $response =  $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome . $url,
71
-                     $this->headers()->getCookie()->httpErrorsFalse()->get()
71
+                        $this->headers()->getCookie()->httpErrorsFalse()->get()
72 72
         );
73 73
 
74 74
         $body = $response->getBody();
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@
 block discarded – undo
57 57
         $urlHome    = config($this->kernel->getPrefixConfig() . '.UrlHome');
58 58
 
59 59
 
60
-        $response =  $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome . $url,
60
+        $response = $this->kernel->getCurl()->request($this->HTTP_TYPE, $urlHome . $url,
61 61
                      $this->headers()->getCookie()->httpErrorsFalse()->get()
62 62
         );
63 63
 
Please login to merge, or discard this patch.
helpers/helpers.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@  discard block
 block discarded – undo
2 2
 
3 3
 use Illuminate\Container\Container;
4 4
 
5
-if (! function_exists('config')) {
5
+if (!function_exists('config')) {
6 6
     /**
7 7
      * Get / set the specified configuration value.
8 8
      *
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
     }
27 27
 }
28 28
 
29
-if (! function_exists('app')) {
29
+if (!function_exists('app')) {
30 30
     /**
31 31
      * Get the available container instance.
32 32
      *
Please login to merge, or discard this patch.