Passed
Push — main ( c6b105...31af8b )
by Thierry
07:02
created
jaxon-attributes/src/AttributeReader.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -258,8 +258,7 @@
 block discarded – undo
258 258
             }
259 259
 
260 260
             return $this->xMetadata;
261
-        }
262
-        catch(Exception|Error $e)
261
+        } catch(Exception|Error $e)
263 262
         {
264 263
             throw new SetupException($e->getMessage());
265 264
         }
Please login to merge, or discard this patch.
jaxon-core/templates/callables/object.js.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,8 @@  discard block
 block discarded – undo
6 6
 if(<?php echo $sJsClass ?> === undefined) {
7 7
     <?php echo $sJsClass ?> = {};
8 8
 }
9
-<?php else: ?>
9
+<?php else {
10
+    : ?>
10 11
 <?php echo $sJsClass ?> = {};
11 12
 <?php endif ?>
12 13
 <?php foreach($this->aMethods as $aMethod): ?>
@@ -17,3 +18,4 @@  discard block
 block discarded – undo
17 18
         echo $sKey ?>: <?php echo $sValue ?><?php endforeach ?> });
18 19
 };
19 20
 <?php endforeach;
21
+}
Please login to merge, or discard this patch.
jaxon-core/src/Di/Container.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -237,7 +237,7 @@
 block discarded – undo
237 237
      */
238 238
     public function val(string $sKey, $xValue)
239 239
     {
240
-       $this->xLibContainer->offsetSet($sKey, $xValue);
240
+        $this->xLibContainer->offsetSet($sKey, $xValue);
241 241
     }
242 242
 
243 243
     /**
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -199,8 +199,7 @@
 block discarded – undo
199 199
         {
200 200
             return $this->xAppContainer != null && $this->xAppContainer->has($sClass) ?
201 201
                 $this->xAppContainer->get($sClass) : $this->xLibContainer->offsetGet($sClass);
202
-        }
203
-        catch(Exception|Throwable $e)
202
+        } catch(Exception|Throwable $e)
204 203
         {
205 204
             $xLogger = $this->g(LoggerInterface::class);
206 205
             $xTranslator = $this->g(Translator::class);
Please login to merge, or discard this patch.
jaxon-core/src/Di/ComponentContainer.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
      */
132 132
     public function set(string $sClass, Closure $xClosure)
133 133
     {
134
-       $this->xContainer->offsetSet($sClass, function() use($xClosure) {
134
+        $this->xContainer->offsetSet($sClass, function() use($xClosure) {
135 135
             return $xClosure($this);
136 136
         });
137 137
     }
@@ -146,7 +146,7 @@  discard block
 block discarded – undo
146 146
      */
147 147
     public function val(string $sKey, $xValue)
148 148
     {
149
-       $this->xContainer->offsetSet($sKey, $xValue);
149
+        $this->xContainer->offsetSet($sKey, $xValue);
150 150
     }
151 151
 
152 152
     /**
Please login to merge, or discard this patch.
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -214,8 +214,7 @@  discard block
 block discarded – undo
214 214
                     return $this->make($this->get($this->getReflectionClassKey($sClassName)));
215 215
                 });
216 216
             }
217
-        }
218
-        catch(ReflectionException $e)
217
+        } catch(ReflectionException $e)
219 218
         {
220 219
             throw new SetupException($this->di->g(Translator::class)
221 220
                 ->trans('errors.class.invalid', ['name' => $sClassName]));
@@ -240,8 +239,7 @@  discard block
 block discarded – undo
240 239
             if($aOptions !== null)
241 240
             {
242 241
                 $this->registerComponent($sClassName, $aOptions);
243
-            }
244
-            else // if(!isset($this->aComponents[$sClassName]))
242
+            } else // if(!isset($this->aComponents[$sClassName]))
245 243
             {
246 244
                 // The component was not found in a registered namespace. We need to parse all
247 245
                 // the directories to be able to find a component registered without a namespace.
Please login to merge, or discard this patch.
jaxon-core/src/Response/Manager/ResponseManager.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -214,8 +214,7 @@
 block discarded – undo
214 214
         if($this->bOnConfirm)
215 215
         {
216 216
             $this->aConfirmCommands[] = $xCommand;
217
-        }
218
-        else
217
+        } else
219 218
         {
220 219
             $this->aCommands[] = $xCommand;
221 220
         }
Please login to merge, or discard this patch.
jaxon-core/src/Response/AbstractResponse.php 1 patch
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -91,15 +91,15 @@
 block discarded – undo
91 91
         return $this->xManager->getErrorMessage();
92 92
     }
93 93
 
94
-     /**
95
-     * Add a response command to the array of commands
96
-     *
97
-     * @param string $sName    The command name
98
-     * @param array|JsonSerializable $aArgs    The command arguments
99
-     * @param bool $bRemoveEmpty
100
-     *
101
-     * @return Command
102
-     */
94
+        /**
95
+         * Add a response command to the array of commands
96
+         *
97
+         * @param string $sName    The command name
98
+         * @param array|JsonSerializable $aArgs    The command arguments
99
+         * @param bool $bRemoveEmpty
100
+         *
101
+         * @return Command
102
+         */
103 103
     public function addCommand(string $sName, array|JsonSerializable $aArgs = [],
104 104
         bool $bRemoveEmpty = false): Command
105 105
     {
Please login to merge, or discard this patch.
jaxon-core/src/Plugin/Manager/PackageManager.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -218,8 +218,7 @@
 block discarded – undo
218 218
         {
219 219
             // A string is supposed to be the path to a config file.
220 220
             $aLibOptions = $this->xConfigManager->read($aLibOptions);
221
-        }
222
-        elseif(!is_array($aLibOptions))
221
+        } elseif(!is_array($aLibOptions))
223 222
         {
224 223
             // Otherwise, anything else than an array is not accepted.
225 224
             $sMessage = $this->xTranslator->trans('errors.register.invalid', ['name' => $sClassName]);
Please login to merge, or discard this patch.
jaxon-core/src/Plugin/Request/CallableClass/CallableClassPlugin.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -85,8 +85,7 @@  discard block
 block discarded – undo
85 85
         if(is_string($xOptions))
86 86
         {
87 87
             $xOptions = ['include' => $xOptions];
88
-        }
89
-        elseif(!is_array($xOptions))
88
+        } elseif(!is_array($xOptions))
90 89
         {
91 90
             throw new SetupException($this->xTranslator->trans('errors.objects.invalid-declaration'));
92 91
         }
@@ -262,8 +261,7 @@  discard block
 block discarded – undo
262 261
 
263 262
             // Unable to find the requested class or method
264 263
             $this->throwException('', 'errors.objects.excluded', $aErrorParams);
265
-        }
266
-        catch(ReflectionException|SetupException $e)
264
+        } catch(ReflectionException|SetupException $e)
267 265
         {
268 266
             // Unable to execute the requested class or method
269 267
             $this->throwException($e->getMessage(), $sError, $aErrorParams);
Please login to merge, or discard this patch.
jaxon-core/src/Plugin/Request/CallableClass/ComponentOptions.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -226,8 +226,7 @@
 block discarded – undo
226 226
             if(is_array($xMethodToCall))
227 227
             {
228 228
                 $aHookMethods[$sCalledMethod] = array_merge($aHookMethods[$sCalledMethod], $xMethodToCall);
229
-            }
230
-            elseif(is_string($xMethodToCall))
229
+            } elseif(is_string($xMethodToCall))
231 230
             {
232 231
                 $aHookMethods[$sCalledMethod][] = $xMethodToCall;
233 232
             }
Please login to merge, or discard this patch.