Passed
Push — master ( 638b9b...570f33 )
by P.R.
01:53
created
src/Wrapper/Wrapper.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -264,7 +264,7 @@
 block discarded – undo
264 264
       }
265 265
     }
266 266
 
267
-    if ($blobArgumentIndex>0)
267
+    if ($blobArgumentIndex > 0)
268 268
     {
269 269
       $this->codeStore->append('');
270 270
     }
Please login to merge, or discard this patch.
src/Helper/Crud/BaseRoutine.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -207,7 +207,7 @@
 block discarded – undo
207 207
     $keys = $this->keyList();
208 208
     if (!empty($keys))
209 209
     {
210
-      if (sizeof($keys)>1 || !isset($keys['PRIMARY']))
210
+      if (sizeof($keys) > 1 || !isset($keys['PRIMARY']))
211 211
       {
212 212
         $this->codeStore->append(' * ', false);
213 213
         $this->codeStore->append(' * Possible keys:', false);
Please login to merge, or discard this patch.
src/MySqlMetaDataLayer.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -400,7 +400,7 @@
 block discarded – undo
400 400
   {
401 401
     $sql = 'select @@sql_mode';
402 402
 
403
-    return (string)$this->executeSingleton1($sql);
403
+    return (string) $this->executeSingleton1($sql);
404 404
   }
405 405
 
406 406
   //--------------------------------------------------------------------------------------------------------------------
Please login to merge, or discard this patch.
src/Backend/MySqlRoutineLoaderWorker.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -304,7 +304,7 @@  discard block
 block discarded – undo
304 304
     $duplicatesMethods = [];
305 305
     foreach ($this->sources as $source)
306 306
     {
307
-      if (sizeof($lookup[$source['method_name']])>1)
307
+      if (sizeof($lookup[$source['method_name']]) > 1)
308 308
       {
309 309
         $duplicatesSources[$source['path_name']]   = $source;
310 310
         $duplicatesMethods[$source['method_name']] = $lookup[$source['method_name']];
@@ -393,7 +393,7 @@  discard block
 block discarded – undo
393 393
   {
394 394
     $this->io->writeln('');
395 395
 
396
-    usort($this->sources, function ($a, $b) {
396
+    usort($this->sources, function($a, $b) {
397 397
       return strcmp($a['routine_name'], $b['routine_name']);
398 398
     });
399 399
 
@@ -473,7 +473,7 @@  discard block
 block discarded – undo
473 473
 
474 474
     $size = $this->characterSets[$key]['maxlen'];
475 475
 
476
-    return (int)floor(self::MAX_COLUMN_SIZE / $size);
476
+    return (int) floor(self::MAX_COLUMN_SIZE / $size);
477 477
   }
478 478
 
479 479
   //--------------------------------------------------------------------------------------------------------------------
Please login to merge, or discard this patch.
src/Backend/MySqlConstantWorker.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -221,7 +221,7 @@  discard block
 block discarded – undo
221 221
             if ($token[0]==T_WHITESPACE)
222 222
             {
223 223
               $line2 = $token[2];
224
-              if (substr_count($token[1], "\n")>1)
224
+              if (substr_count($token[1], "\n") > 1)
225 225
               {
226 226
                 // Whitespace contains new line: end doc block without constants.
227 227
                 $step = 4;
@@ -248,7 +248,7 @@  discard block
 block discarded – undo
248 248
           {
249 249
             if ($token[0]==T_WHITESPACE)
250 250
             {
251
-              if (substr_count($token[1], "\n")<=1)
251
+              if (substr_count($token[1], "\n") <= 1)
252 252
               {
253 253
                 // Ignore whitespace.
254 254
                 $line3 = $token[2];
@@ -430,7 +430,7 @@  discard block
 block discarded – undo
430 430
     foreach ($this->constants as $constant => $value)
431 431
     {
432 432
       $width1 = max(mb_strlen($constant), $width1);
433
-      $width2 = max(mb_strlen((string)$value), $width2);
433
+      $width2 = max(mb_strlen((string) $value), $width2);
434 434
     }
435 435
 
436 436
     $format = sprintf('  const %%-%ds = %%%dd;', $width1, $width2);
@@ -477,7 +477,7 @@  discard block
 block discarded – undo
477 477
       foreach ($table as $column)
478 478
       {
479 479
         $width1 = max(mb_strlen($column['column_name']), $width1);
480
-        $width2 = max(mb_strlen((string)$column['length']), $width2);
480
+        $width2 = max(mb_strlen((string) $column['length']), $width2);
481 481
       }
482 482
 
483 483
       foreach ($table as $column)
@@ -486,7 +486,7 @@  discard block
 block discarded – undo
486 486
         {
487 487
           if (isset($column['constant_name']))
488 488
           {
489
-            $format  = sprintf("%%s.%%-%ds %%%dd %%s\n", $width1, $width2);
489
+            $format = sprintf("%%s.%%-%ds %%%dd %%s\n", $width1, $width2);
490 490
             $content .= sprintf($format,
491 491
                                 $column['table_name'],
492 492
                                 $column['column_name'],
@@ -495,7 +495,7 @@  discard block
 block discarded – undo
495 495
           }
496 496
           else
497 497
           {
498
-            $format  = sprintf("%%s.%%-%ds %%%dd\n", $width1, $width2);
498
+            $format = sprintf("%%s.%%-%ds %%%dd\n", $width1, $width2);
499 499
             $content .= sprintf($format,
500 500
                                 $column['table_name'],
501 501
                                 $column['column_name'],
Please login to merge, or discard this patch.
src/Helper/SqlModeHelper.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -91,7 +91,7 @@
 block discarded – undo
91 91
     if ($this->currentSqlMode!==$this->canonicalSqlModeWithOracle)
92 92
     {
93 93
       $this->dl->setSqlMode($this->canonicalSqlModeWithOracle);
94
-      $this->currentSqlMode = (string)$this->canonicalSqlModeWithOracle;
94
+      $this->currentSqlMode = (string) $this->canonicalSqlModeWithOracle;
95 95
     }
96 96
   }
97 97
 
Please login to merge, or discard this patch.
src/Exception/MySqlQueryErrorException.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -97,7 +97,7 @@
 block discarded – undo
97 97
    */
98 98
   protected function composerMessage(): array
99 99
   {
100
-    return array_merge($this->splitIntoTwoColumns('MySQL Errno', (string)$this->errno),
100
+    return array_merge($this->splitIntoTwoColumns('MySQL Errno', (string) $this->errno),
101 101
                        $this->splitIntoTwoColumns('Error', $this->error),
102 102
                        $this->splitIntoTwoColumns('Query', $this->query),
103 103
                        $this->splitIntoTwoColumns('Method', $this->method));
Please login to merge, or discard this patch.
src/Exception/MySqlDataLayerException.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -87,7 +87,7 @@
 block discarded – undo
87 87
    */
88 88
   protected function composerMessage(): array
89 89
   {
90
-    return array_merge($this->splitIntoTwoColumns('MySQL Errno', (string)$this->errno),
90
+    return array_merge($this->splitIntoTwoColumns('MySQL Errno', (string) $this->errno),
91 91
                        $this->splitIntoTwoColumns('Error', $this->error),
92 92
                        $this->splitIntoTwoColumns('Method', $this->method));
93 93
   }
Please login to merge, or discard this patch.
src/MySqlDataLayer.php 1 patch
Spacing   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -326,11 +326,11 @@  discard block
 block discarded – undo
326 326
           $line = '';
327 327
           foreach ($row as $i => $field)
328 328
           {
329
-            if ($i>0)
329
+            if ($i > 0)
330 330
             {
331 331
               $line .= ' ';
332 332
             }
333
-            $line .= str_pad((string)$field, $fields[$i]->max_length);
333
+            $line .= str_pad((string) $field, $fields[$i]->max_length);
334 334
           }
335 335
           echo date('Y-m-d H:i:s'), ' ', $line, "\n";
336 336
           $n++;
@@ -703,16 +703,16 @@  discard block
 block discarded – undo
703 703
       $query            = "show variables like 'max_allowed_packet'";
704 704
       $maxAllowedPacket = $this->executeRow1($query);
705 705
 
706
-      $this->maxAllowedPacket = (int)$maxAllowedPacket['Value'];
706
+      $this->maxAllowedPacket = (int) $maxAllowedPacket['Value'];
707 707
 
708 708
       // Note: When setting $chunkSize equal to $maxAllowedPacket it is not possible to transmit a LOB
709 709
       // with size $maxAllowedPacket bytes (but only $maxAllowedPacket - 8 bytes). But when setting the size of
710 710
       // $chunkSize less than $maxAllowedPacket than it is possible to transmit a LOB with size
711 711
       // $maxAllowedPacket bytes.
712
-      $this->chunkSize = (int)min($this->maxAllowedPacket - 8, 1024 * 1024);
712
+      $this->chunkSize = (int) min($this->maxAllowedPacket - 8, 1024 * 1024);
713 713
     }
714 714
 
715
-    return (int)$this->maxAllowedPacket;
715
+    return (int) $this->maxAllowedPacket;
716 716
   }
717 717
 
718 718
   //--------------------------------------------------------------------------------------------------------------------
@@ -800,7 +800,7 @@  discard block
 block discarded – undo
800 800
 
801 801
     if (is_int($value) || is_float($value))
802 802
     {
803
-      return (string)$value;
803
+      return (string) $value;
804 804
     }
805 805
 
806 806
     return "'".$this->mysqli->real_escape_string($value)."'";
@@ -821,7 +821,7 @@  discard block
 block discarded – undo
821 821
       return 'null';
822 822
     }
823 823
 
824
-    return (string)$value;
824
+    return (string) $value;
825 825
   }
826 826
 
827 827
   //--------------------------------------------------------------------------------------------------------------------
@@ -839,7 +839,7 @@  discard block
 block discarded – undo
839 839
       return 'null';
840 840
     }
841 841
 
842
-    return (string)$value;
842
+    return (string) $value;
843 843
   }
844 844
 
845 845
   //--------------------------------------------------------------------------------------------------------------------
@@ -1140,7 +1140,7 @@  discard block
 block discarded – undo
1140 1140
     {
1141 1141
       $n = strlen($data);
1142 1142
       $p = 0;
1143
-      while ($p<$n)
1143
+      while ($p < $n)
1144 1144
       {
1145 1145
         $success = @$statement->send_long_data($paramNr, substr($data, $p, $this->chunkSize));
1146 1146
         if (!$success)
@@ -1183,13 +1183,13 @@  discard block
 block discarded – undo
1183 1183
     foreach ($columns as $column)
1184 1184
     {
1185 1185
       $separator .= str_repeat('-', $column['length'] + 2).'+';
1186
-      $spaces    = ($column['length'] + 2) - mb_strlen((string)$column['header']);
1186
+      $spaces = ($column['length'] + 2) - mb_strlen((string) $column['header']);
1187 1187
 
1188
-      $spacesLeft  = (int)floor($spaces / 2);
1189
-      $spacesRight = (int)ceil($spaces / 2);
1188
+      $spacesLeft  = (int) floor($spaces / 2);
1189
+      $spacesRight = (int) ceil($spaces / 2);
1190 1190
 
1191
-      $fillerLeft  = ($spacesLeft>0) ? str_repeat(' ', $spacesLeft) : '';
1192
-      $fillerRight = ($spacesRight>0) ? str_repeat(' ', $spacesRight) : '';
1191
+      $fillerLeft  = ($spacesLeft > 0) ? str_repeat(' ', $spacesLeft) : '';
1192
+      $fillerRight = ($spacesRight > 0) ? str_repeat(' ', $spacesRight) : '';
1193 1193
 
1194 1194
       $header .= $fillerLeft.$column['header'].$fillerRight.'|';
1195 1195
     }
@@ -1208,7 +1208,7 @@  discard block
 block discarded – undo
1208 1208
    */
1209 1209
   private function executeTableShowTableColumn(array $column, mixed $value): void
1210 1210
   {
1211
-    $spaces = str_repeat(' ', max($column['length'] - mb_strlen((string)$value), 0));
1211
+    $spaces = str_repeat(' ', max($column['length'] - mb_strlen((string) $value), 0));
1212 1212
 
1213 1213
     switch ($column['type'])
1214 1214
     {
Please login to merge, or discard this patch.